summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/xcb_disp.c11
1 files changed, 10 insertions, 1 deletions
diff --git a/src/xcb_disp.c b/src/xcb_disp.c
index fe1bdbfd..99e08365 100644
--- a/src/xcb_disp.c
+++ b/src/xcb_disp.c
@@ -1,6 +1,10 @@
/* Copyright (C) 2003-2006 Jamey Sharp, Josh Triplett
* This file is licensed under the MIT license. See the file COPYING. */
+#ifdef HAVE_CONFIG_H
+#include <config.h>
+#endif
+
#include "Xlibint.h"
#include "Xxcbint.h"
#include <xcb/xcbext.h>
@@ -73,7 +77,12 @@ int _XConnectXCB(Display *dpy, _Xconst char *display, char **fullnamep, int *scr
return 0;
}
- snprintf(*fullnamep, len, "%s:%d.%d", host, n, *screenp);
+#ifdef HAVE_LAUNCHD
+ if(strncmp(host, "/tmp/launch", 11) == 0)
+ snprintf(*fullnamep, len, "%s:%d", host, n);
+ else
+#endif
+ snprintf(*fullnamep, len, "%s:%d.%d", host, n, *screenp);
free(host);
_XLockMutex(_Xglobal_lock);