From b02996ac125f754bf5e0f32d4ca0d5747e4fb986 Mon Sep 17 00:00:00 2001 From: Michal Srb Date: Wed, 1 Apr 2015 17:35:44 +0300 Subject: Warn about not reseting Xvnc and terminate instead. VNC prevents X server restarting even when -reset is explicitly given. Print out message with explanation and terminate instead. --- unix/xserver/hw/vnc/xvnc.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'unix') diff --git a/unix/xserver/hw/vnc/xvnc.c b/unix/xserver/hw/vnc/xvnc.c index 6aad434b..d4e9daeb 100644 --- a/unix/xserver/hw/vnc/xvnc.c +++ b/unix/xserver/hw/vnc/xvnc.c @@ -1566,7 +1566,12 @@ vfbScreenInit(ScreenPtr pScreen, int argc, char **argv) static void vfbClientStateChange(CallbackListPtr *a, void *b, void *c) { - dispatchException &= ~DE_RESET; + if (dispatchException & DE_RESET) { + ErrorF("Warning: VNC extension does not support -reset, terminating instead. Use -noreset to prevent termination.\n"); + + dispatchException |= DE_TERMINATE; + dispatchException &= ~DE_RESET; + } } #if XORG >= 113 -- cgit v1.2.3 From af8c9fb9c2c5a5993d938c8547b9f82f1c2dda4e Mon Sep 17 00:00:00 2001 From: Michal Srb Date: Fri, 10 Apr 2015 16:56:54 +0300 Subject: Enable and document syslog logger in Xvnc. --- unix/xserver/hw/vnc/RFBGlue.cc | 2 ++ unix/xserver/hw/vnc/Xvnc.man | 10 +++++----- 2 files changed, 7 insertions(+), 5 deletions(-) (limited to 'unix') diff --git a/unix/xserver/hw/vnc/RFBGlue.cc b/unix/xserver/hw/vnc/RFBGlue.cc index 19338fc7..09832ab7 100644 --- a/unix/xserver/hw/vnc/RFBGlue.cc +++ b/unix/xserver/hw/vnc/RFBGlue.cc @@ -23,6 +23,7 @@ #include #include #include +#include #include "RFBGlue.h" @@ -34,6 +35,7 @@ static LogWriter inputLog("Input"); void vncInitRFB(void) { rfb::initStdIOLoggers(); + rfb::initSyslogLogger(); rfb::LogWriter::setLogParams("*:stderr:30"); rfb::Configuration::enableServerParams(); } diff --git a/unix/xserver/hw/vnc/Xvnc.man b/unix/xserver/hw/vnc/Xvnc.man index 18957bf9..9e86fa4f 100644 --- a/unix/xserver/hw/vnc/Xvnc.man +++ b/unix/xserver/hw/vnc/Xvnc.man @@ -274,11 +274,11 @@ stop non-SSH connections from any other hosts. . .TP .B \-Log \fIlogname\fP:\fIdest\fP:\fIlevel\fP -Configures the debug log settings. \fIdest\fP can currently be \fBstderr\fP or -\fBstdout\fP, and \fIlevel\fP is between 0 and 100, 100 meaning most verbose -output. \fIlogname\fP is usually \fB*\fP meaning all, but you can target a -specific source file if you know the name of its "LogWriter". Default is -\fB*:stderr:30\fP. +Configures the debug log settings. \fIdest\fP can currently be \fBstderr\fP, +\fBstdout\fP or \fBsyslog\fP, and \fIlevel\fP is between 0 and 100, 100 meaning +most verbose output. \fIlogname\fP is usually \fB*\fP meaning all, but you can +target a specific source file if you know the name of its "LogWriter". Default +is \fB*:stderr:30\fP. . .TP .B \-RemapKeys \fImapping -- cgit v1.2.3