diff options
| author | runge <runge@karlrunge.com> | 2009-03-16 11:09:53 -0400 |
|---|---|---|
| committer | runge <runge@karlrunge.com> | 2009-03-16 11:09:53 -0400 |
| commit | 128ee3ec4ebe6dce7d002c33c932c76183c0fa76 (patch) | |
| tree | 790e9262aa1376aaf18a1895dc1a1a602cd5465f /x11vnc/util.c | |
| parent | 9ae2e8391de9f2e37193c321cc67d526c3ff919f (diff) | |
| download | libtdevnc-128ee3ec4ebe6dce7d002c33c932c76183c0fa76.tar.gz libtdevnc-128ee3ec4ebe6dce7d002c33c932c76183c0fa76.zip | |
Add some -remap tricks. Limit rfbCFD message count.
Diffstat (limited to 'x11vnc/util.c')
| -rw-r--r-- | x11vnc/util.c | 13 |
1 files changed, 12 insertions, 1 deletions
diff --git a/x11vnc/util.c b/x11vnc/util.c index dfb617d..e7f7863 100644 --- a/x11vnc/util.c +++ b/x11vnc/util.c @@ -568,7 +568,18 @@ void rfbCFD(long usec) { return; } if (unixpw && unixpw_in_progress && !unixpw_in_rfbPE) { - rfbLog("unixpw_in_rfbPE: skipping rfbCFD\n"); + static int msgs = 0; + static double last_reset = 0.0; + if (dnow() > last_reset + 5.0) { + msgs = 0; + last_reset = dnow(); + } + if (msgs++ < 10) { + rfbLog("unixpw_in_rfbPE: skipping rfbCFD\n"); + if (msgs == 10) { + rfbLog("unixpw_in_rfbPE: skipping rfbCFD ...\n"); + } + } return; } if (usec > USEC_MAX) { |
