< prev index next >
src/java.base/windows/native/libjli/java_md.c
Print this page
*** 46,55 ****
--- 46,59 ----
*/
static jboolean GetJVMPath(const char *jrepath, const char *jvmtype,
char *jvmpath, jint jvmpathsize);
static jboolean GetJREPath(char *path, jint pathsize);
+ #ifdef USE_REGISTRY_LOOKUP
+ jboolean GetPublicJREHome(char *buf, jint bufsize);
+ #endif
+
/* We supports warmup for UI stack that is performed in parallel
* to VM initialization.
* This helps to improve startup of UI application as warmup phase
* might be long due to initialization of OS or hardware resources.
* It is not CPU bound and therefore it does not interfere with VM init.
*** 344,353 ****
--- 348,365 ----
JLI_TraceLauncher("JRE path is %s\n", path);
return JNI_TRUE;
}
}
+ #ifdef USE_REGISTRY_LOOKUP
+ /* Lookup public JRE using Windows registry. */
+ if (GetPublicJREHome(path, pathsize)) {
+ JLI_TraceLauncher("JRE path is %s\n", path);
+ return JNI_TRUE;
+ }
+ #endif
+
JLI_ReportErrorMessage(JRE_ERROR8 JAVA_DLL);
return JNI_FALSE;
}
/*
< prev index next >