src/share/bin/java.c::TranslateApplicationArgs
static void
TranslateApplicationArgs(int jargc, const char **jargv, int *pargc, char ***pargv)
{
int argc = *pargc;
char **argv = *pargv;
int nargc = argc + jargc;
char **nargv = JLI_MemAlloc((nargc + 1) * sizeof(char *));
int i;
*pargc = nargc;
*pargv = nargv;
for (i = 0; i < jargc; i++) {
const char *arg = jargv[i];
if (arg[0] == '-' && arg[1] == 'J') {
*nargv++ = ((arg + 2) == NULL) ? NULL : JLI_StringDup(arg + 2);
}
}
for (i = 0; i < argc; i++) {
char *arg = argv[i];
if (arg[0] == '-' && arg[1] == 'J') {
if (arg[2] == '\0') {
JLI_ReportErrorMessage(ARG_ERROR3);
exit(1);
}
*nargv++ = arg + 2;
}
}
for (i = 0; i < jargc ; i++) {
const char *arg = jargv[i];
if (arg[0] != '-' || arg[1] != 'J') {
*nargv++ = (arg == NULL) ? NULL : JLI_StringDup(arg);
}
}
for (i = 0; i < argc; i++) {
char *arg = argv[i];
if (arg[0] == '-') {
if (arg[1] == 'J')
continue;
if (IsWildCardEnabled() && arg[1] == 'c'
&& (JLI_StrCmp(arg, "-cp") == 0 ||
JLI_StrCmp(arg, "-classpath") == 0)
&& i < argc - 1) {
*nargv++ = arg;
*nargv++ = (char *) JLI_WildcardExpandClasspath(argv[i+1]);
i++;
continue;
}
}
*nargv++ = arg;
}
*nargv = 0;
}
src/share/bin/java.c::IsWildCardEnabled
static jboolean
IsWildCardEnabled()
{
return _wc_enabled;
}
src/share/bin/defines.h::EXPAND_CLASSPATH_WILDCARDS
#ifdef EXPAND_CLASSPATH_WILDCARDS
static const jboolean const_cpwildcard = JNI_TRUE;
#else
static const jboolean const_cpwildcard = JNI_FALSE;
#endif