Commit 15d04d46 authored by runge's avatar runge

x11vnc: lower -wait and -defer to 20ms. Drop client doing ultravnc stuff in...

x11vnc: lower -wait and -defer to 20ms. Drop client doing ultravnc stuff in -unixpw during login phase.
parent 1d495291
2007-05-06 Karl Runge <runge@karlrunge.com>
* x11vnc: lower -wait and -defer to 20ms. Change some SSL
debug output. Drop client doing ultravnc stuff in -unixpw
during login phase.
2007-05-05 Karl Runge <runge@karlrunge.com> 2007-05-05 Karl Runge <runge@karlrunge.com>
* x11vnc: add groups handling for -users mode. * x11vnc: add groups handling for -users mode.
......
This diff is collapsed.
...@@ -338,11 +338,11 @@ int flip_byte_order = 0; /* sometimes needed when using_shm = 0 */ ...@@ -338,11 +338,11 @@ int flip_byte_order = 0; /* sometimes needed when using_shm = 0 */
* waitms is the msec to wait between screen polls. Not too old h/w shows * waitms is the msec to wait between screen polls. Not too old h/w shows
* poll times of 10-35ms, so maybe this value cuts the idle load by 2 or so. * poll times of 10-35ms, so maybe this value cuts the idle load by 2 or so.
*/ */
int waitms = 30; int waitms = 20;
double wait_ui = 2.0; double wait_ui = 2.0;
double slow_fb = 0.0; double slow_fb = 0.0;
int wait_bog = 1; int wait_bog = 1;
int defer_update = 30; /* deferUpdateTime ms to wait before sends. */ int defer_update = 20; /* deferUpdateTime ms to wait before sends. */
int got_defer = 0; int got_defer = 0;
int got_deferupdate = 0; int got_deferupdate = 0;
......
...@@ -1863,7 +1863,7 @@ if (db) fprintf(stderr, "iface: %s\n", iface); ...@@ -1863,7 +1863,7 @@ if (db) fprintf(stderr, "iface: %s\n", iface);
if (strstr(rcookie, uniq) == rcookie) { if (strstr(rcookie, uniq) == rcookie) {
int i; int i;
rfbLog("SSL: but https for helper process succeeded.\n"); rfbLog("SSL: BUT WAIT! HTTPS for helper process succeeded. Good.\n");
if (mode != OPENSSL_HTTPS) { if (mode != OPENSSL_HTTPS) {
last_https = time(NULL); last_https = time(NULL);
for (i=0; i<128; i++) { for (i=0; i<128; i++) {
...@@ -2066,52 +2066,52 @@ if (db > 1) fprintf(stderr, "ssl_init: 4\n"); ...@@ -2066,52 +2066,52 @@ if (db > 1) fprintf(stderr, "ssl_init: 4\n");
} else if (err == SSL_ERROR_WANT_READ) { } else if (err == SSL_ERROR_WANT_READ) {
if (db) fprintf(stderr, "got SSL_ERROR_WANT_READ\n"); if (db) fprintf(stderr, "got SSL_ERROR_WANT_READ\n");
rfbLog("SSL: ssl_helper: SSL_accept() failed for: %s\n", rfbLog("SSL: ssl_helper[%d]: SSL_accept() failed for: %s\n",
name); getpid(), name);
return 0; return 0;
} else if (err == SSL_ERROR_WANT_WRITE) { } else if (err == SSL_ERROR_WANT_WRITE) {
if (db) fprintf(stderr, "got SSL_ERROR_WANT_WRITE\n"); if (db) fprintf(stderr, "got SSL_ERROR_WANT_WRITE\n");
rfbLog("SSL: ssl_helper: SSL_accept() failed for: %s\n", rfbLog("SSL: ssl_helper[%d]: SSL_accept() failed for: %s\n",
name); getpid(), name);
return 0; return 0;
} else if (err == SSL_ERROR_SYSCALL) { } else if (err == SSL_ERROR_SYSCALL) {
if (db) fprintf(stderr, "got SSL_ERROR_SYSCALL\n"); if (db) fprintf(stderr, "got SSL_ERROR_SYSCALL\n");
rfbLog("SSL: ssl_helper: SSL_accept() failed for: %s\n", rfbLog("SSL: ssl_helper[%d]: SSL_accept() failed for: %s\n",
name); getpid(), name);
return 0; return 0;
} else if (err == SSL_ERROR_ZERO_RETURN) { } else if (err == SSL_ERROR_ZERO_RETURN) {
if (db) fprintf(stderr, "got SSL_ERROR_ZERO_RETURN\n"); if (db) fprintf(stderr, "got SSL_ERROR_ZERO_RETURN\n");
rfbLog("SSL: ssl_helper: SSL_accept() failed for: %s\n", rfbLog("SSL: ssl_helper[%d]: SSL_accept() failed for: %s\n",
name); getpid(), name);
return 0; return 0;
} else if (rc < 0) { } else if (rc < 0) {
rfbLog("SSL: ssl_helper: SSL_accept() *FATAL: %d\n", rc); rfbLog("SSL: ssl_helper[%d]: SSL_accept() *FATAL: %d\n", getpid(), rc);
return 0; return 0;
} else if (dnow() > start + 3.0) { } else if (dnow() > start + 3.0) {
rfbLog("SSL: ssl_helper: timeout looping SSL_accept() " rfbLog("SSL: ssl_helper[%d]: timeout looping SSL_accept() "
"fatal.\n"); "fatal.\n", getpid());
return 0; return 0;
} else { } else {
BIO *bio = SSL_get_rbio(ssl); BIO *bio = SSL_get_rbio(ssl);
if (bio == NULL) { if (bio == NULL) {
rfbLog("SSL: ssl_helper: ssl BIO is null. " rfbLog("SSL: ssl_helper[%d]: ssl BIO is null. "
"fatal.\n"); "fatal.\n", getpid());
return 0; return 0;
} }
if (BIO_eof(bio)) { if (BIO_eof(bio)) {
rfbLog("SSL: ssl_helper: ssl BIO is EOF. " rfbLog("SSL: ssl_helper[%d]: ssl BIO is EOF. "
"fatal.\n"); "fatal.\n", getpid());
return 0; return 0;
} }
} }
......
...@@ -2,7 +2,7 @@ ...@@ -2,7 +2,7 @@
.TH X11VNC "1" "May 2007" "x11vnc " "User Commands" .TH X11VNC "1" "May 2007" "x11vnc " "User Commands"
.SH NAME .SH NAME
x11vnc - allow VNC connections to real X11 displays x11vnc - allow VNC connections to real X11 displays
version: 0.9.1, lastmod: 2007-05-05 version: 0.9.1, lastmod: 2007-05-06
.SH SYNOPSIS .SH SYNOPSIS
.B x11vnc .B x11vnc
[OPTION]... [OPTION]...
...@@ -3213,12 +3213,12 @@ times for more output. ...@@ -3213,12 +3213,12 @@ times for more output.
\fB-defer\fR \fItime\fR \fB-defer\fR \fItime\fR
.IP .IP
Time in ms to wait for updates before sending to client Time in ms to wait for updates before sending to client
(deferUpdateTime) Default: 30 (deferUpdateTime) Default: 20
.PP .PP
\fB-wait\fR \fItime\fR \fB-wait\fR \fItime\fR
.IP .IP
Time in ms to pause between screen polls. Used to cut Time in ms to pause between screen polls. Used to cut
down on load. Default: 30 down on load. Default: 20
.PP .PP
\fB-wait_ui\fR \fIfactor\fR \fB-wait_ui\fR \fIfactor\fR
.IP .IP
......
...@@ -15,7 +15,7 @@ int xtrap_base_event_type = 0; ...@@ -15,7 +15,7 @@ int xtrap_base_event_type = 0;
int xdamage_base_event_type = 0; int xdamage_base_event_type = 0;
/* date +'lastmod: %Y-%m-%d' */ /* date +'lastmod: %Y-%m-%d' */
char lastmod[] = "0.9.1 lastmod: 2007-05-05"; char lastmod[] = "0.9.1 lastmod: 2007-05-06";
/* X display info */ /* X display info */
......
...@@ -1296,7 +1296,8 @@ void set_single_window(rfbClientPtr cl, int x, int y) { ...@@ -1296,7 +1296,8 @@ void set_single_window(rfbClientPtr cl, int x, int y) {
return; return;
} }
if (unixpw_in_progress) { if (unixpw_in_progress) {
rfbLog("set_single_window: unixpw_in_progress, skipping.\n"); rfbLog("set_single_window: unixpw_in_progress, dropping client.\n");
rfbCloseClient(cl);
return; return;
} }
if (cl->viewOnly) { if (cl->viewOnly) {
...@@ -1342,7 +1343,8 @@ void set_server_input(rfbClientPtr cl, int grab) { ...@@ -1342,7 +1343,8 @@ void set_server_input(rfbClientPtr cl, int grab) {
return; return;
} }
if (unixpw_in_progress) { if (unixpw_in_progress) {
rfbLog("set_server_input: unixpw_in_progress, skipping.\n"); rfbLog("set_server_input: unixpw_in_progress, dropping client.\n");
rfbCloseClient(cl);
return; return;
} }
if (cl->viewOnly) { if (cl->viewOnly) {
...@@ -1389,7 +1391,8 @@ void set_text_chat(rfbClientPtr cl, int len, char *txt) { ...@@ -1389,7 +1391,8 @@ void set_text_chat(rfbClientPtr cl, int len, char *txt) {
fprintf(stderr, "'\n"); fprintf(stderr, "'\n");
#endif #endif
if (unixpw_in_progress) { if (unixpw_in_progress) {
rfbLog("set_text_chat: unixpw_in_progress, skipping.\n"); rfbLog("set_text_chat: unixpw_in_progress, dropping client.\n");
rfbCloseClient(cl);
return; return;
} }
iter = rfbGetClientIterator(screen); iter = rfbGetClientIterator(screen);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment