The VNC server can display a bug where screen updates stop happening until the client moves the mouse. This can be very annoying for keyboard-based applications, and for server-based changes.
Note that the server changes do happen -- they are just not displayed.
This happens when the option DeferUpdate is turned on. This option is turned on by default, and is set to 40 ms. The idea is to buffer updates every 40 ms to prevent overuse of network and cpu resources.
The problem is that the VNC server never resets the timer. If something outside of VNC resets the Xlib timer (eg. logout), the timer is wrong, and you will only receive screen updates after a very long time. The fix here is to reset the timer every time VNC connects.
This does mean that you have to disconnect/reconnect when the problem starts happening, but I'm loathe to mess with further X internals.
--- unix/xc/programs/Xserver/vnc/XserverDesktop.cc.timer 2010-06-04 11:18:07.000000000
+0200
+++ unix/xc/programs/Xserver/vnc/XserverDesktop.cc 2010-06-04 11:48:45.000000000 +0200
@@ -1000,6 +1000,10 @@
}
dev->kbdfeed->ctrl = ctrl;
(*dev->kbdfeed->CtrlProc)(dev, &dev->kbdfeed->ctrl);
+ vlog.info("Resetting keyboard timer.");
+ deferredUpdateTimerSet = false;
+ deferredUpdateTimer = 0;
+ server->tryUpdate();
}
bool XserverDesktop::getKeyRepeat()
No comments:
Post a Comment