Ignore cruft at the end of the version string.
This commit is contained in:
@@ -538,7 +538,7 @@ public class Application
|
|||||||
|
|
||||||
// parse the version out of the java.version system property
|
// parse the version out of the java.version system property
|
||||||
String verstr = System.getProperty("java.version");
|
String verstr = System.getProperty("java.version");
|
||||||
Matcher m = Pattern.compile("(\\d+)\\.(\\d+)\\.(\\d+)(_\\d+)?").matcher(verstr);
|
Matcher m = Pattern.compile("(\\d+)\\.(\\d+)\\.(\\d+)(_\\d+)?.*").matcher(verstr);
|
||||||
if (!m.matches()) {
|
if (!m.matches()) {
|
||||||
// if we can't parse the java version we're in weird land and should probably just try
|
// if we can't parse the java version we're in weird land and should probably just try
|
||||||
// our luck with what we've got rather than try to download a new jvm
|
// our luck with what we've got rather than try to download a new jvm
|
||||||
|
|||||||
Reference in New Issue
Block a user