changeset 16615:e170c858888e jdk-9+155

8173711: Disable JAVA_OPTIONS env variable support until JDK-8173712 is resolved Reviewed-by: ksrini, henryjen
author mchung
date Tue, 31 Jan 2017 14:47:57 -0800
parents 69342000c9a9
children 802428c8b55d 7bd7a7ffa84b
files src/java.base/share/native/libjli/args.c test/ProblemList.txt test/tools/launcher/I18NArgTest.java
diffstat 3 files changed, 8 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/src/java.base/share/native/libjli/args.c	Tue Jan 31 21:33:54 2017 +0000
+++ b/src/java.base/share/native/libjli/args.c	Tue Jan 31 14:47:57 2017 -0800
@@ -429,6 +429,10 @@
 }
 
 jboolean JLI_AddArgsFromEnvVar(JLI_List args, const char *var_name) {
+
+#ifndef ENABLE_JAVA_OPTIONS
+    return JNI_FALSE;
+#else
     char *env = getenv(var_name);
     char *p, *arg;
     char quote;
@@ -515,6 +519,7 @@
     }
 
     return JNI_TRUE;
+#endif
 }
 
 #ifdef DEBUG_ARGFILE
--- a/test/ProblemList.txt	Tue Jan 31 21:33:54 2017 +0000
+++ b/test/ProblemList.txt	Tue Jan 31 14:47:57 2017 -0800
@@ -253,6 +253,7 @@
 
 tools/pack200/CommandLineTests.java                             8059906 generic-all
 
+tools/launcher/ArgsEnvVar.java					8173712 generic-all
 tools/launcher/FXLauncherTest.java                              8068049 linux-all,macosx-all
 
 tools/jimage/JImageExtractTest.java                             8169713 generic-all
--- a/test/tools/launcher/I18NArgTest.java	Tue Jan 31 21:33:54 2017 +0000
+++ b/test/tools/launcher/I18NArgTest.java	Tue Jan 31 14:47:57 2017 -0800
@@ -96,6 +96,7 @@
         }
 
         // Test via JAVA_OPTIONS
+/*
         Map<String, String> env = new HashMap<>();
         String cmd = "-Dtest.src=" + TEST_SOURCES_DIR.getAbsolutePath() +
                 " -Dtest.classes=" + TEST_CLASSES_DIR.getAbsolutePath() +
@@ -108,6 +109,7 @@
             System.err.println(tr);
             throw new RuntimeException("test fails");
         }
+*/
     }
 
     static void testCharacters(String... args) {