diff options
author | Pierre Ossman <ossman@cendio.se> | 2015-03-03 16:43:20 +0100 |
---|---|---|
committer | Pierre Ossman <ossman@cendio.se> | 2015-03-03 16:43:20 +0100 |
commit | f10d2a7cb0bd28743971dc5edc3e3fff298fa264 (patch) | |
tree | b12dacfca14e885b34875365b8b2210bb2249e87 | |
parent | 7d218b08a3da0a6d2bc277b642788f1d9c9fcaad (diff) | |
download | tigervnc-f10d2a7cb0bd28743971dc5edc3e3fff298fa264.tar.gz tigervnc-f10d2a7cb0bd28743971dc5edc3e3fff298fa264.zip |
Wrong array index in CPU usage calculation on Windows
-rw-r--r-- | tests/util.cxx | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/tests/util.cxx b/tests/util.cxx index 52a2c610..419f09ca 100644 --- a/tests/util.cxx +++ b/tests/util.cxx @@ -107,7 +107,7 @@ double getCpuCounter(cpucounter_t c) counters[1] = (uint64_t)s[1].dwHighDateTime << 32 | s[1].dwLowDateTime; - seconds = (double)(counters[1] - counters[2]) / 10000000.0; + seconds = (double)(counters[1] - counters[0]) / 10000000.0; #else seconds = (double)(s[1].ru_utime.tv_sec - s[0].ru_utime.tv_sec); |