From 9d2f75b905163b508c9fc4a5b4816c2be03e100b Mon Sep 17 00:00:00 2001 From: Aleksey Bragin Date: Thu, 13 Jul 2006 20:47:59 +0000 Subject: [PATCH] Added a check for a non-null WndProc into IntCallWndProcA/W. Instead of bugchecking, it shows a DPRINT1 now to inform about a bug. As a side effect, mIRC now works in ReactOS. svn path=/trunk/; revision=23046 --- reactos/dll/win32/user32/windows/message.c | 12 ++++++++++++ 1 file changed, 12 insertions(+) diff --git a/reactos/dll/win32/user32/windows/message.c b/reactos/dll/win32/user32/windows/message.c index f4bf39cde4d..78794293b0c 100644 --- a/reactos/dll/win32/user32/windows/message.c +++ b/reactos/dll/win32/user32/windows/message.c @@ -1141,6 +1141,12 @@ IntCallWindowProcW(BOOL IsAnsiProc, MSG UnicodeMsg; LRESULT Result; + if (WndProc == NULL) + { + DPRINT1("IntCallWindowsProcW() called with WndProc = NULL!\n"); + return FALSE; + } + if (IsAnsiProc) { UnicodeMsg.hwnd = hWnd; @@ -1177,6 +1183,12 @@ IntCallWindowProcA(BOOL IsAnsiProc, MSG UnicodeMsg; LRESULT Result; + if (WndProc == NULL) + { + DPRINT1("IntCallWindowsProcA() called with WndProc = NULL!\n"); + return FALSE; + } + if (IsAnsiProc) { return WndProc(hWnd, Msg, wParam, lParam);