summaryrefslogtreecommitdiff
path: root/tools/qvfb
diff options
context:
space:
mode:
authorJeremy Katz <jeremy.katz@nokia.com>2009-10-02 12:53:47 +0200
committerJeremy Katz <jeremy.katz@nokia.com>2009-10-02 12:58:17 +0200
commit1eafe0ea2ecc3bce733d574f39bc26652baaec38 (patch)
tree6f66f6798f84183c7743e517199579a6eb1b0732 /tools/qvfb
parenta586b10bfbf2540e282568b99a4facefa4f24853 (diff)
downloadqt4-tools-1eafe0ea2ecc3bce733d574f39bc26652baaec38.tar.gz
make private qws/qvfb data directory non-default, default to non-user specific
This turns the changes in 072e748adbdab1d51b240b9983ce82b213b66f18 off by default. Define QT_PRIVATE_QWS to turn them on. This must be done for both qvfb (X11 build) and libQtGui (QWS build). Failure to do so will result in an inability for applications to communicate with the server. Task-number: QTBUG-1711 Reviewed-by: Paul
Diffstat (limited to 'tools/qvfb')
-rw-r--r--tools/qvfb/qvfb.cpp2
-rw-r--r--tools/qvfb/qvfbshmem.cpp6
2 files changed, 5 insertions, 3 deletions
diff --git a/tools/qvfb/qvfb.cpp b/tools/qvfb/qvfb.cpp
index 611941937d..59e8dae726 100644
--- a/tools/qvfb/qvfb.cpp
+++ b/tools/qvfb/qvfb.cpp
@@ -135,7 +135,7 @@ static const char *red_off_led_xpm[] = {
static bool copyButtonConfiguration(const QString &prefix, int displayId)
{
- const QString destDir = QT_VFB_DATADIR(displayId);
+ const QString destDir = QT_VFB_DATADIR(displayId).append("/");
const QFileInfo src(prefix + QLatin1String("defaultbuttons.conf"));
const QFileInfo dst(destDir + QLatin1String("defaultbuttons.conf"));
unlink(dst.absoluteFilePath().toLatin1().constData());
diff --git a/tools/qvfb/qvfbshmem.cpp b/tools/qvfb/qvfbshmem.cpp
index 8c4cdb979f..5a2da0d5f5 100644
--- a/tools/qvfb/qvfbshmem.cpp
+++ b/tools/qvfb/qvfbshmem.cpp
@@ -128,7 +128,9 @@ QShMemViewProtocol::QShMemViewProtocol(int displayid, const QSize &s,
if ( logname )
username = logname;
- QString oldPipe = "/tmp/qtembedded-" + username + "/" + QString(QTE_PIPE).arg(displayid);
+ qws_dataDir(displayid);
+
+ QString oldPipe = "/tmp/qtembedded-" + username + "/" + QString("QtEmbedded-%1").arg(displayid);
int oldPipeSemkey = ftok(oldPipe.toLatin1().constData(), 'd');
if (oldPipeSemkey != -1) {
int oldPipeLockId = semget(oldPipeSemkey, 0, 0);
@@ -149,7 +151,7 @@ QShMemViewProtocol::QShMemViewProtocol(int displayid, const QSize &s,
}
}
- displayPipe = qws_dataDir(displayid).append(QTE_PIPE);
+ displayPipe = QTE_PIPE_QVFB(displayid);
kh = new QVFbKeyPipeProtocol(displayid);
/* should really depend on receiving qt version, but how can