Temp fix for SetWindowTextA()
Jason Campbell
rexregis at verizon.net
Sun Jun 5 13:26:40 CDT 2005
Although I guess it's not allowed by MSDN, most Diablo II bots have been
programmed to change the window title of D2 itself.
A possible better patch may be to see if D2 is a child of the D2 bot
(since most bots can load D2) and allow the title change if it is and
not allow it if it's not a parent/child.
Leaving original code in, but remarked, so we don't lose it if it gets
patched. That way once a parent/child patch (or any other better patch)
gets finished, everything can be back to normal by removing the remarks.
Jason Campbell
jason at sysk-net.com
===================================================================
--- win.c 2005-05-14 14:49:19.000000000 -0400
+++ win.c 2005-06-05 14:15:33.000000000 -0400
@@ -2293,9 +2293,10 @@
}
if (!WIN_IsCurrentProcess( hwnd ))
{
- FIXME( "cannot set text %s of other process window %p\n",
debugstr_a(lpString), hwnd );
- SetLastError( ERROR_ACCESS_DENIED );
- return FALSE;
+// FIXME( "cannot set text %s of other process window %p\n",
debugstr_a(lpString), hwnd );
+// SetLastError( ERROR_ACCESS_DENIED );
+// return FALSE;
+ FIXME( "not allowed by MSDN but needed by Diablo II bots\n");
}
return (BOOL)SendMessageA( hwnd, WM_SETTEXT, 0, (LPARAM)lpString );
}
More information about the wine-patches
mailing list