From: Constantin Kaplinsky Date: Fri, 10 Feb 2006 06:43:56 +0000 (+0000) Subject: Improved debugging version of the poll() method. X-Git-Tag: v0.0.90~384^2~356 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=6e34af4228ba3c0d997a0e2c0e203a1c7c69b8f8;p=tigervnc.git Improved debugging version of the poll() method. git-svn-id: svn://svn.code.sf.net/p/tigervnc/code/trunk@479 3789f03b-4d11-0410-bbf8-ca57d06f2519 --- diff --git a/x0vncserver/PollingManager.cxx b/x0vncserver/PollingManager.cxx index 3e5aa3e7..99f97874 100644 --- a/x0vncserver/PollingManager.cxx +++ b/x0vncserver/PollingManager.cxx @@ -152,6 +152,7 @@ void PollingManager::pollDebug() timeSaved.tv_sec = 0; timeSaved.tv_usec = 0; gettimeofday(&timeSaved, &tz); + int step = m_pollingStep; poll(); @@ -159,7 +160,7 @@ void PollingManager::pollDebug() int diff = (int)((timeNow.tv_usec - timeSaved.tv_usec + 500) / 1000 + (timeNow.tv_sec - timeSaved.tv_sec) * 1000); if (diff != 0) - fprintf(stderr, "DEBUG: poll(): %4d ms\n", diff); + fprintf(stderr, "DEBUG: poll(): %4d ms [step %2d]\n", diff, step % 32); } //