mirror of
https://github.com/openjdk/jdk.git
synced 2025-09-17 17:44:40 +02:00
8067366: Allow java.{endorsed,ext}.dirs property be set to empty string
Reviewed-by: alanb, hseigel
This commit is contained in:
parent
51bda75a8f
commit
d57a134a2b
1 changed files with 8 additions and 5 deletions
|
@ -2997,17 +2997,20 @@ jint Arguments::parse_each_vm_init_arg(const JavaVMInitArgs* args,
|
||||||
#endif
|
#endif
|
||||||
// -D
|
// -D
|
||||||
} else if (match_option(option, "-D", &tail)) {
|
} else if (match_option(option, "-D", &tail)) {
|
||||||
if (match_option(option, "-Djava.endorsed.dirs=", &tail)) {
|
const char* value;
|
||||||
|
if (match_option(option, "-Djava.endorsed.dirs=", &value) &&
|
||||||
|
*value!= '\0' && strcmp(value, "\"\"") != 0) {
|
||||||
// abort if -Djava.endorsed.dirs is set
|
// abort if -Djava.endorsed.dirs is set
|
||||||
jio_fprintf(defaultStream::output_stream(),
|
jio_fprintf(defaultStream::output_stream(),
|
||||||
"-Djava.endorsed.dirs is not supported. Endorsed standards and standalone APIs\n"
|
"-Djava.endorsed.dirs=%s is not supported. Endorsed standards and standalone APIs\n"
|
||||||
"in modular form will be supported via the concept of upgradeable modules.\n");
|
"in modular form will be supported via the concept of upgradeable modules.\n", value);
|
||||||
return JNI_EINVAL;
|
return JNI_EINVAL;
|
||||||
}
|
}
|
||||||
if (match_option(option, "-Djava.ext.dirs=", &tail)) {
|
if (match_option(option, "-Djava.ext.dirs=", &value) &&
|
||||||
|
*value != '\0' && strcmp(value, "\"\"") != 0) {
|
||||||
// abort if -Djava.ext.dirs is set
|
// abort if -Djava.ext.dirs is set
|
||||||
jio_fprintf(defaultStream::output_stream(),
|
jio_fprintf(defaultStream::output_stream(),
|
||||||
"-Djava.ext.dirs is not supported. Use -classpath instead.\n");
|
"-Djava.ext.dirs=%s is not supported. Use -classpath instead.\n", value);
|
||||||
return JNI_EINVAL;
|
return JNI_EINVAL;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue