summaryrefslogtreecommitdiffstats
path: root/x11vnc/x11vnc.c
diff options
context:
space:
mode:
authorrunge <runge>2008-05-08 01:23:45 +0000
committerrunge <runge>2008-05-08 01:23:45 +0000
commitabbdf92a704790374a12d6da5125b4e95595aaac (patch)
tree55fdb539e7b9d2e0447668f1dad77c96df22aeb1 /x11vnc/x11vnc.c
parentd8812f8c85fcd83412c6ad275d10ce1c43f22240 (diff)
downloadlibtdevnc-abbdf92a.tar.gz
libtdevnc-abbdf92a.zip
x11vnc: add UltraVNC repeater proxy support. fix to setp gui
mode. -threads is now strongly discouraged. Read PORT= in url. User can set nolisten for Xvfb in -create mode. clean up wait_for_client() to some degree.
Diffstat (limited to 'x11vnc/x11vnc.c')
-rw-r--r--x11vnc/x11vnc.c17
1 files changed, 16 insertions, 1 deletions
diff --git a/x11vnc/x11vnc.c b/x11vnc/x11vnc.c
index 5b07ee0..af6b8f2 100644
--- a/x11vnc/x11vnc.c
+++ b/x11vnc/x11vnc.c
@@ -2589,7 +2589,7 @@ int main(int argc, char* argv[]) {
} else if (!strcmp(arg, "-connect") ||
!strcmp(arg, "-connect_or_exit")) {
CHECK_ARGC
- if (strchr(argv[++i], '/')) {
+ if (strchr(argv[++i], '/' && !strstr(argv[i], "repeater://"))) {
client_connect_file = strdup(argv[i]);
} else {
client_connect = strdup(argv[i]);
@@ -3280,7 +3280,22 @@ int main(int argc, char* argv[]) {
}
#if LIBVNCSERVER_HAVE_LIBPTHREAD
} else if (!strcmp(arg, "-threads")) {
+#if defined(X11VNC_THREADED)
use_threads = 1;
+#else
+ if (getenv("X11VNC_THREADED")) {
+ use_threads = 1;
+ } else {
+ rfbLog("\n");
+ rfbLog("The -threads mode is unstable and not tested or maintained.\n");
+ rfbLog("It is disabled in the source code. If you really need\n");
+ rfbLog("the feature you can reenable it at build time by setting\n");
+ rfbLog("-DX11VNC_THREADED in CPPFLAGS. Or set X11VNC_THREADED=1\n");
+ rfbLog("in your runtime environment.\n");
+ rfbLog("\n");
+ usleep(500*1000);
+ }
+#endif
} else if (!strcmp(arg, "-nothreads")) {
use_threads = 0;
#endif