src/java.base/windows/native/libjava/jdk_util_md.c
changeset 58493 55a8d95c7787
parent 47216 71c04702a3d5
equal deleted inserted replaced
58492:227ddf1ff93d 58493:55a8d95c7787
    26 #include <windows.h>
    26 #include <windows.h>
    27 #include "jdk_util.h"
    27 #include "jdk_util.h"
    28 
    28 
    29 #define JVM_DLL "jvm.dll"
    29 #define JVM_DLL "jvm.dll"
    30 
    30 
    31 static HMODULE jvm_handle = NULL;
       
    32 
       
    33 int JDK_InitJvmHandle() {
       
    34     jvm_handle = GetModuleHandle(JVM_DLL);
       
    35     return (jvm_handle != NULL);
       
    36 }
       
    37 
       
    38 void* JDK_FindJvmEntry(const char* name) {
       
    39     return (void*) GetProcAddress(jvm_handle, name);
       
    40 }
       
    41 
       
    42 JNIEXPORT HMODULE JDK_LoadSystemLibrary(const char* name) {
    31 JNIEXPORT HMODULE JDK_LoadSystemLibrary(const char* name) {
    43     HMODULE handle = NULL;
    32     HMODULE handle = NULL;
    44     char path[MAX_PATH];
    33     char path[MAX_PATH];
    45 
    34 
    46     if (GetSystemDirectory(path, sizeof(path)) != 0) {
    35     if (GetSystemDirectory(path, sizeof(path)) != 0) {