aboutsummaryrefslogtreecommitdiffstats
path: root/testing
diff options
context:
space:
mode:
authoraclement <aclement>2005-09-15 13:54:13 +0000
committeraclement <aclement>2005-09-15 13:54:13 +0000
commitd01e7fced891648a3d4bdff481c041d76763cf86 (patch)
tree37cbabfef09883f684aba1f299bffd8763840bde /testing
parent3466a78126c79116bed284bfebfadc529243b11e (diff)
downloadaspectj-d01e7fced891648a3d4bdff481c041d76763cf86.tar.gz
aspectj-d01e7fced891648a3d4bdff481c041d76763cf86.zip
use the right version property.
Diffstat (limited to 'testing')
-rw-r--r--testing/newsrc/org/aspectj/testing/AjcTest.java9
1 files changed, 4 insertions, 5 deletions
diff --git a/testing/newsrc/org/aspectj/testing/AjcTest.java b/testing/newsrc/org/aspectj/testing/AjcTest.java
index dc30e420a..860a3ca72 100644
--- a/testing/newsrc/org/aspectj/testing/AjcTest.java
+++ b/testing/newsrc/org/aspectj/testing/AjcTest.java
@@ -29,11 +29,10 @@ public class AjcTest {
private static boolean is14VMOrGreater = true;
private static boolean is15VMOrGreater = false;
- static {
- String vm = System.getProperty("java.runtime.version");
- if (vm == null) {
- vm = System.getProperty("java.vm.version");
- }
+ static { // matching logic is also in org.aspectj.util.LangUtil
+ String vm = System.getProperty("java.version"); // JLS 20.18.7
+ if (vm==null) vm = System.getProperty("java.runtime.version");
+ if (vm==null) vm = System.getProperty("java.vm.version");
if (vm.startsWith("1.3")) {
is14VMOrGreater = false;
} else if (vm.startsWith("1.5")) {