8152721: Java Web Start splash mechanism is not working in JDK9
Reviewed-by: alanb, ksrini
This commit is contained in:
parent
8e7633221f
commit
a852e6e5d0
@ -108,6 +108,7 @@ static void SetAddExportsProp(const jint n, const char *s);
|
|||||||
static void SetPatchProp(const jint n, const char *s);
|
static void SetPatchProp(const jint n, const char *s);
|
||||||
static void SelectVersion(int argc, char **argv, char **main_class);
|
static void SelectVersion(int argc, char **argv, char **main_class);
|
||||||
static void SetJvmEnvironment(int argc, char **argv);
|
static void SetJvmEnvironment(int argc, char **argv);
|
||||||
|
static jboolean IsWhiteSpaceOptionArgument(const char* name);
|
||||||
static jboolean ParseArguments(int *pargc, char ***pargv,
|
static jboolean ParseArguments(int *pargc, char ***pargv,
|
||||||
int *pmode, char **pwhat,
|
int *pmode, char **pwhat,
|
||||||
int *pret, const char *jrepath);
|
int *pret, const char *jrepath);
|
||||||
@ -499,6 +500,20 @@ JavaMain(void * _args)
|
|||||||
LEAVE();
|
LEAVE();
|
||||||
}
|
}
|
||||||
|
|
||||||
|
/*
|
||||||
|
* Test if the given option name has a whitespace separated argument.
|
||||||
|
*/
|
||||||
|
jboolean
|
||||||
|
IsWhiteSpaceOptionArgument(const char* name) {
|
||||||
|
return JLI_StrCmp(name, "-classpath") == 0 ||
|
||||||
|
JLI_StrCmp(name, "-cp") == 0 ||
|
||||||
|
JLI_StrCmp(name, "-modulepath") == 0 ||
|
||||||
|
JLI_StrCmp(name, "-mp") == 0 ||
|
||||||
|
JLI_StrCmp(name, "-upgrademodulepath") == 0 ||
|
||||||
|
JLI_StrCmp(name, "-addmods") == 0 ||
|
||||||
|
JLI_StrCmp(name, "-limitmods") == 0;
|
||||||
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
* Checks the command line options to find which JVM type was
|
* Checks the command line options to find which JVM type was
|
||||||
* specified. If no command line option was given for the JVM type,
|
* specified. If no command line option was given for the JVM type,
|
||||||
@ -534,13 +549,7 @@ CheckJvmType(int *pargc, char ***argv, jboolean speculative) {
|
|||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
} else {
|
} else {
|
||||||
if (JLI_StrCmp(arg, "-classpath") == 0 ||
|
if (IsWhiteSpaceOptionArgument(arg)) {
|
||||||
JLI_StrCmp(arg, "-cp") == 0 ||
|
|
||||||
JLI_StrCmp(arg, "-modulepath") == 0 ||
|
|
||||||
JLI_StrCmp(arg, "-mp") == 0 ||
|
|
||||||
JLI_StrCmp(arg, "-upgrademodulepath") == 0 ||
|
|
||||||
JLI_StrCmp(arg, "-addmods") == 0 ||
|
|
||||||
JLI_StrCmp(arg, "-limitmods") == 0) {
|
|
||||||
newArgv[newArgvIdx++] = arg;
|
newArgv[newArgvIdx++] = arg;
|
||||||
argi++;
|
argi++;
|
||||||
if (argi < argc) {
|
if (argi < argc) {
|
||||||
@ -682,9 +691,7 @@ SetJvmEnvironment(int argc, char **argv) {
|
|||||||
if (i > 0) {
|
if (i > 0) {
|
||||||
char *prev = argv[i - 1];
|
char *prev = argv[i - 1];
|
||||||
// skip non-dash arg preceded by class path specifiers
|
// skip non-dash arg preceded by class path specifiers
|
||||||
if (*arg != '-' &&
|
if (*arg != '-' && IsWhiteSpaceOptionArgument(prev)) {
|
||||||
((JLI_StrCmp(prev, "-cp") == 0
|
|
||||||
|| JLI_StrCmp(prev, "-classpath") == 0))) {
|
|
||||||
continue;
|
continue;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -1028,9 +1035,7 @@ SelectVersion(int argc, char **argv, char **main_class)
|
|||||||
} else {
|
} else {
|
||||||
if (JLI_StrCmp(arg, "-jar") == 0)
|
if (JLI_StrCmp(arg, "-jar") == 0)
|
||||||
jarflag = 1;
|
jarflag = 1;
|
||||||
/* deal with "unfortunate" classpath syntax */
|
if (IsWhiteSpaceOptionArgument(arg) && (argc >= 2)) {
|
||||||
if ((JLI_StrCmp(arg, "-classpath") == 0 || JLI_StrCmp(arg, "-cp") == 0) &&
|
|
||||||
(argc >= 2)) {
|
|
||||||
argc--;
|
argc--;
|
||||||
argv++;
|
argv++;
|
||||||
arg = *argv;
|
arg = *argv;
|
||||||
|
Loading…
x
Reference in New Issue
Block a user