From b02996ac125f754bf5e0f32d4ca0d5747e4fb986 Mon Sep 17 00:00:00 2001 From: Michal Srb Date: Wed, 1 Apr 2015 17:35:44 +0300 Subject: [PATCH] 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(-) 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 -- 2.39.5