Commit 8b36b631 authored by Bertho Stultiens's avatar Bertho Stultiens Committed by Alexandre Julliard

Fixed wrong NE module registration so that resources work.

parent eec4c254
......@@ -27,6 +27,7 @@ DECLARE_DEBUG_CHANNEL(elfdll)
/*------------------ HACKS -----------------*/
extern DWORD fixup_imports(WINE_MODREF *wm);
extern void dump_exports(HMODULE hModule);
/*---------------- END HACKS ---------------*/
char *extra_ld_library_path = NULL; /* The extra search-path set in wine.conf */
......@@ -254,13 +255,16 @@ static WINE_MODREF *ELFDLL_CreateModref(HMODULE hModule, LPCSTR path)
*/
static HMODULE16 ELFDLL_CreateNEModule(NE_MODULE *ne_image, DWORD size)
{
NE_MODULE *pModule;
HMODULE16 hModule = GLOBAL_CreateBlock(GMEM_MOVEABLE, ne_image, size, 0,
FALSE, FALSE, FALSE, NULL);
if(!hModule)
return (HMODULE16)0;
FarSetOwner16(hModule, hModule);
NE_RegisterModule(ne_image);
pModule = (NE_MODULE *)GlobalLock16(hModule);
pModule->self = hModule;
NE_RegisterModule(pModule);
return hModule;
}
......@@ -326,6 +330,8 @@ WINE_MODREF *ELFDLL_LoadLibraryExA(LPCSTR path, DWORD flags, DWORD *err)
return NULL;
}
dump_exports(image->pe_module_start);
*err = 0;
return wm;
}
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment