changeset 242:0b919385c073

Fixing the simple time conversion bug in GC MXBean handling.
author shade
date Wed, 13 Nov 2013 16:35:36 +0100
parents 8e1914f965b4
children 6f818942cdc3
files jmh-core/src/main/java/org/openjdk/jmh/runner/BaseRunner.java
diffstat 1 files changed, 1 insertions(+), 1 deletions(-) [+]
line wrap: on
line diff
--- a/jmh-core/src/main/java/org/openjdk/jmh/runner/BaseRunner.java	Tue Nov 12 16:42:13 2013 +0100
+++ b/jmh-core/src/main/java/org/openjdk/jmh/runner/BaseRunner.java	Wed Nov 13 16:35:36 2013 +0100
@@ -174,7 +174,7 @@
             }
 
             long start = System.nanoTime();
-            while (System.nanoTime() - start < MAX_WAIT_MSEC) {
+            while (TimeUnit.NANOSECONDS.toMillis(System.nanoTime() - start) < MAX_WAIT_MSEC) {
                 try {
                     TimeUnit.MILLISECONDS.sleep(200);
                 } catch (InterruptedException e) {