aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authortrialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38>2008-06-01 09:42:39 +0000
committertrialuser02 <trialuser02@90c681e8-e032-0410-971d-27865f9a5e38>2008-06-01 09:42:39 +0000
commit810d10487b56dd7765ae7b3b461c4feb216368b7 (patch)
tree239e495c316e4a90bdd6d3a17a46c57834ebe1e4 /src
parentd22e58bf97516718933354cf38ef7cb97a087ec5 (diff)
downloadqmmp-810d10487b56dd7765ae7b3b461c4feb216368b7.tar.gz
qmmp-810d10487b56dd7765ae7b3b461c4feb216368b7.tar.bz2
qmmp-810d10487b56dd7765ae7b3b461c4feb216368b7.zip
fixed crash
git-svn-id: http://svn.code.sf.net/p/qmmp-dev/code/trunk/qmmp@394 90c681e8-e032-0410-971d-27865f9a5e38
Diffstat (limited to 'src')
-rw-r--r--src/ui/qmmpstarter.cpp2
-rw-r--r--src/ui/version.h3
2 files changed, 2 insertions, 3 deletions
diff --git a/src/ui/qmmpstarter.cpp b/src/ui/qmmpstarter.cpp
index 085cc4713..4d47ffabd 100644
--- a/src/ui/qmmpstarter.cpp
+++ b/src/ui/qmmpstarter.cpp
@@ -22,7 +22,7 @@
#include "unixdomainsocket.h"
#include <unistd.h>
-#include <stdio.h>
+#include <sys/types.h>
#include <string.h>
#include "mainwindow.h"
diff --git a/src/ui/version.h b/src/ui/version.h
index 6eaa365d2..a2933b31a 100644
--- a/src/ui/version.h
+++ b/src/ui/version.h
@@ -10,6 +10,5 @@
#endif
#define LISTEN_PORT_BASE 33000
-#define UDS_PATH strcat(strdup("/tmp/qmmp.sock."), cuserid(0))
-
+#define UDS_PATH QString("/tmp/qmmp.sock.%1").arg(getuid()).toAscii().constData()
#endif