* dlfcn.cc (dlopen): Disable old 32 bit code on 64 bit.

* dcrt0.cc (check_sanity_and_sync): Ditto.
	* dll_init.cc (dll_dllcrt0_1): Fix typo in comment.
This commit is contained in:
Corinna Vinschen
2014-10-10 15:29:18 +00:00
parent 7a84e9c4bc
commit 3ab591cf71
4 changed files with 13 additions and 1 deletions

View File

@ -640,7 +640,7 @@ dll_dllcrt0_1 (VOID *x)
when loaded either statically or dynamically. Because this leaves
a stale pointer into demapped memory space if the DLL is unloaded
by a call to dlclose, we prevent this happening for dynamically
loaded DLLS in dlopen by saving and restoring cxx_malloc around
loaded DLLs in dlopen by saving and restoring cxx_malloc around
the call to LoadLibrary, which invokes the DLL's startup sequence.
Modern DLLs won't even attempt to override the pointer when loaded
statically, but will write their overrides directly into the