diff --git a/if1632/kernel.spec b/if1632/kernel.spec index 71372240076..be68a6ee674 100644 --- a/if1632/kernel.spec +++ b/if1632/kernel.spec @@ -356,7 +356,7 @@ file krnl386.exe 449 pascal GetpWin16Lock() GetpWin16Lock16 450 pascal VWin32_EventWait(long) VWin32_EventWait 451 pascal VWin32_EventSet(long) VWin32_EventSet -452 pascal LoadLibrary32(str) LoadLibraryA +452 pascal LoadLibrary32(str) LoadLibrary32_16 453 pascal GetProcAddress32(long str) GetProcAddress32_16 454 equate __FLATCS 0 # initialized by BUILTIN_Init() 455 equate __FLATDS 0 # initialized by BUILTIN_Init() @@ -386,7 +386,7 @@ file krnl386.exe 479 pascal KERNEL_479(long) VWin32_EventSet # ??? 480 pascal16 _EnterWin16Lock() SYSLEVEL_EnterWin16Lock 481 pascal16 _LeaveWin16Lock() SYSLEVEL_LeaveWin16Lock -482 pascal LoadSystemLibrary32(str) LoadLibraryA # FIXME! +482 pascal LoadSystemLibrary32(str) LoadLibrary32_16 # FIXME! 483 stub MapProcessHandle 484 pascal SetProcessDWORD(long s_word long) SetProcessDword 485 pascal GetProcessDWORD(long s_word) GetProcessDword diff --git a/loader/module.c b/loader/module.c index 1e03123174d..4ea51e0b4f9 100644 --- a/loader/module.c +++ b/loader/module.c @@ -1314,13 +1314,25 @@ DWORD WINAPI GetModuleFileNameW( HMODULE hModule, LPWSTR lpFileName, /*********************************************************************** * LoadLibraryEx32W (KERNEL.513) - * FIXME */ HMODULE WINAPI LoadLibraryEx32W16( LPCSTR libname, HANDLE16 hf, - DWORD flags ) + DWORD flags ) { - TRACE_(module)("(%s,%d,%08lx)\n",libname,hf,flags); - return LoadLibraryExA(libname, hf,flags); + HMODULE hModule; + + SYSLEVEL_ReleaseWin16Lock(); + hModule = LoadLibraryExA( libname, hf, flags ); + SYSLEVEL_RestoreWin16Lock(); + + return hModule; +} + +/*********************************************************************** + * LoadLibrary32_16 (KERNEL.452) + */ +HMODULE WINAPI LoadLibrary32_16( LPCSTR libname ) +{ + return LoadLibraryEx32W16( libname, 0, 0 ); } /***********************************************************************