[Bug 44460] Wine' s loader should prevent multiple executable mappings of images (dlls) backed by the same physical file (long path vs. short path)

wine-bugs at winehq.org wine-bugs at winehq.org
Wed Feb 28 18:37:42 CST 2018


https://bugs.winehq.org/show_bug.cgi?id=44460

Anastasius Focht <focht at gmx.net> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
      Fixed by SHA1|                            |1cee60d06823a6224646b425243
                   |                            |ed0617c4d1c0f
         Resolution|---                         |FIXED
             Status|NEW                         |RESOLVED

--- Comment #1 from Anastasius Focht <focht at gmx.net> ---
Hello folks,

this is fixed by commit
https://source.winehq.org/git/wine.git/commitdiff/1cee60d06823a6224646b425243ed0617c4d1c0f

Thanks Alexandre

--- snip ---
$ pwd
/home/focht/.wine/drive_c/Program Files/CMS

$ WINEDEBUG=+seh,+relay,+module wine ./CMS.exe >>log.txt 2>&1
...
003f:Call KERNEL32.LoadLibraryA(01375fb0 "C:\\Program
Files\\CMS\\WndManager.ocx") ret=00404efc 
...
003f:Ret  PE DLL (proc=0x15ab467,module=0x1590000
L"WndManager.ocx",reason=PROCESS_ATTACH,res=(nil)) retval=1
003f:trace:module:process_attach (L"WndManager.ocx",(nil)) - END
003f:Ret  KERNEL32.LoadLibraryA() retval=01590000 ret=00404efc
003f:Call KERNEL32.GetProcAddress(01590000,0050d090 "DllRegisterServer")
ret=00404fa9
003f:Ret  KERNEL32.GetProcAddress() retval=015a0010 ret=00404fa9
...
003f:Call KERNEL32.LoadLibraryExW(0032bc8e L"C:\\Program
Files\\CMS\\WndManager.ocx",00000000,0000000b) ret=7e3b701c
003f:trace:module:LdrGetDllHandle L"C:\\Program Files\\CMS\\WndManager.ocx" ->
0x1590000 (load path L"C:\\Program
Files\\CMS;C:\\windows\\system32;C:\\windows\\system;C:\\windows;.;C:\\windows\\system32;C:\\windows;C:\\windows\\system32\\wbem")
003f:trace:module:LdrAddRefDll (L"WndManager.ocx") ldr.LoadCount: 2
003f:Ret  KERNEL32.LoadLibraryExW() retval=01590000 ret=7e3b701c
...
003f:Call KERNEL32.FreeLibrary(01590000) ret=7e3b6f87 
003f:trace:module:LdrUnloadDll (0x1590000)
003f:trace:module:LdrUnloadDll (L"WndManager.ocx") - START
003f:trace:module:MODULE_DecRefCount (L"WndManager.ocx") ldr.LoadCount: 1
003f:trace:module:LdrUnloadDll END
003f:Ret  KERNEL32.FreeLibrary() retval=00000001 ret=7e3b6f87
...
003f:Call KERNEL32.GetShortPathNameA(0032bcb4 "C:\\Program
Files\\CMS\\WndManager.ocx",00f304a0,00000104) ret=5f411ddd
003f:Ret  KERNEL32.GetShortPathNameA() retval=0000001c ret=5f411ddd
...
003f:Call KERNEL32.LoadLibraryExW(00329bee
L"C:\\PROG~FBU\\CMS\\WNDM~VNJ.OCX",00000000,00000008) ret=7e598fff
003f:trace:module:load_dll looking for L"C:\\PROG~FBU\\CMS\\WNDM~VNJ.OCX" in
L"C:\\PROG~FBU\\CMS;C:\\windows\\system32;C:\\windows\\system;C:\\windows;.;C:\\windows\\system32;C:\\windows;C:\\windows\\system32\\wbem"
003f:trace:module:open_dll_file L"\\??\\C:\\PROG~FBU\\CMS\\WNDM~VNJ.OCX" is the
same file as existing module 0x1590000 L"C:\\Program
Files\\CMS\\WndManager.ocx"
003f:trace:module:load_dll Found L"C:\\Program Files\\CMS\\WndManager.ocx" for
L"C:\\PROG~FBU\\CMS\\WNDM~VNJ.OCX" at 0x1590000, count=2
003f:Ret  KERNEL32.LoadLibraryExW() retval=01590000 ret=7e598fff 
...
--- snip ---

"same file as existing module" = identity check works.

$ wine --version
wine-3.2-293-g0a72708126

Regards

-- 
Do not reply to this email, post in Bugzilla using the
above URL to reply.
You are receiving this mail because:
You are watching all bug changes.



More information about the wine-bugs mailing list