changeset 1260:d9fc8a523df3

7901481: Version check updates Contributed-by: Nitsan Wakart <nitsanw@azulsystems.com>
author shade
date Thu, 13 Aug 2015 15:48:02 +0300
parents d48b4ec11d95
children 0c56a3867bd7
files jmh-core/src/main/java/org/openjdk/jmh/runner/CompilerHints.java
diffstat 1 files changed, 4 insertions(+), 7 deletions(-) [+]
line wrap: on
line diff
--- a/jmh-core/src/main/java/org/openjdk/jmh/runner/CompilerHints.java	Fri Jul 17 14:35:06 2015 +0300
+++ b/jmh-core/src/main/java/org/openjdk/jmh/runner/CompilerHints.java	Thu Aug 13 15:48:02 2015 +0300
@@ -30,12 +30,7 @@
 import java.io.File;
 import java.io.IOException;
 import java.io.Reader;
-import java.util.ArrayList;
-import java.util.Collections;
-import java.util.Iterator;
-import java.util.List;
-import java.util.Set;
-import java.util.TreeSet;
+import java.util.*;
 
 public class CompilerHints extends AbstractResourceReader {
 
@@ -107,7 +102,9 @@
             try {
                 // get the version digits
                 String[] versionDigits = version.substring(version.indexOf('_') + 1).split("\\.");
-                if (Integer.valueOf(versionDigits[0]) >= 5 && Integer.valueOf(versionDigits[1]) >= 10) {
+                if (Integer.valueOf(versionDigits[0]) > 5) {
+                    return true;
+                } else if (Integer.valueOf(versionDigits[0]) == 5 && Integer.valueOf(versionDigits[1]) >= 10) {
                     return true;
                 }
             } catch (NumberFormatException e) {