ntdll: import dll from dir of referring dll if not found instandard locations

Hongbo Ni hongbo_ni at hotmail.com
Sun Aug 3 01:45:15 CDT 2008


"Dmitry Timoshkov" <dmitry at codeweavers.com> wrote:> > This patch fixes bug 14699. It should fix all failed applications> > which try to load a dll from specific folder, and the dll is link> > another dll in the same folder.> > Please add a test case for this behaviour to confirm that your patch> is doing a correct thing.Please ignore this patch. This is not how window work. Window&Wine solve it byLoadLibraryExW(module, NULL, LOAD_WITH_ALTERED_SEARCH_PATH)  I will post another patch to just solve bug 14699. As discussed in my prev email: RE: DLL loading prolem when injecting into another process‏ @ -322,7 +322,7 @@ void *get_hook_proc( void *proc, const WCHAR *module ){     TRACE( "loading %s\n", debugstr_w(module) );     /* FIXME: the library will never be freed */-    if (!(mod = LoadLibraryW(module))) return NULL;+   if (!(mod = LoadLibraryExW(module, NULL, LOAD_WITH_ALTERED_SEARCH_PATH))) return NULL;   }   return (char *)mod + (ULONG_PTR)proc;}Currently there is no test case to show LoadLibraryW above has loaded the module in the processother than current process. But how can I write test case to justify using LoadLibraryExW instead LoadLibraryW above ?  How can I know if another process has loaded the DLL containing GetMsgProc when I am trying to callSetWindowsHookEx(WH_GETMESSAGE, GetMsgProc, g_hinstDll,GetWindowThreadProcessId(hwnd, NULL)); Hongbo Ni
_________________________________________________________________
Meet singles near you. Try ninemsn dating now!
http://a.ninemsn.com.au/b.aspx?URL=http%3A%2F%2Fdating%2Eninemsn%2Ecom%2Eau%2Fchannel%2Findex%2Easpx%3Ftrackingid%3D1046247&_t=773166080&_r=WL_TAGLINE&_m=EXT
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://www.winehq.org/pipermail/wine-devel/attachments/20080803/77ed54a8/attachment.htm 


More information about the wine-devel mailing list