<html>
<head>
<style>
.hmmessage P
{
margin:0px;
padding:0px
}
body.hmmessage
{
FONT-SIZE: 10pt;
FONT-FAMILY:Tahoma
}
</style>
</head>
<body class='hmmessage'>
"Dmitry Timoshkov" &lt;<A href="mailto:dmitry@codeweavers.com">dmitry@codeweavers.com</A>&gt; wrote:<BR><BR>&gt; &gt; This patch fixes bug 14699. It should fix all failed applications<BR>&gt; &gt; which try to load a dll from specific folder, and the dll is link<BR>&gt; &gt; another dll in the same folder.<BR>&gt; <BR>&gt; Please add a test case for this behaviour to confirm that your patch<BR>&gt; is doing a correct thing.<BR><BR>Please ignore this patch. This is not how window work. Window&amp;Wine solve it by<BR>LoadLibraryExW(module, NULL, LOAD_WITH_ALTERED_SEARCH_PATH) <BR>&nbsp;<BR>I will post another patch to just solve bug 14699.<BR>&nbsp;<BR>As discussed in my prev email: RE: DLL loading prolem when injecting into another process�<BR>&nbsp;<BR>@ -322,7 +322,7 @@ void *get_hook_proc( void *proc, const WCHAR *module )<BR>{<BR>&nbsp;&nbsp;&nbsp;&nbsp; TRACE( "loading %s\n", debugstr_w(module) );<BR>&nbsp;&nbsp;&nbsp;&nbsp; /* FIXME: the library will never be freed */<BR>-&nbsp;&nbsp;&nbsp; if (!(mod = LoadLibraryW(module))) return NULL;<BR>+&nbsp;&nbsp;&nbsp;if (!(mod = LoadLibraryExW(module, NULL, LOAD_WITH_ALTERED_SEARCH_PATH))) return NULL;<BR>&nbsp;&nbsp; }<BR>&nbsp;&nbsp; return (char *)mod + (ULONG_PTR)proc;<BR>}<BR><BR>Currently there is no test case to show LoadLibraryW above has loaded the module in the process<BR>other than current process.<BR>&nbsp;<BR>But how can I write test case to justify using LoadLibraryExW instead&nbsp;LoadLibraryW above&nbsp;? <BR>&nbsp;<BR>How can I know if another process has loaded the DLL containing GetMsgProc when I am trying to call<BR>SetWindowsHookEx(WH_GETMESSAGE, GetMsgProc, g_hinstDll,GetWindowThreadProcessId(hwnd, NULL));<BR><BR>&nbsp;<BR>Hongbo Ni<BR><br /><hr /> in your area now! <a href='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' target='_new'>View photos of singles</a></body>
</html>