mirror of
https://github.com/reactos/reactos.git
synced 2025-02-24 17:34:57 +00:00
fix broken condition in CallWindowProc
svn path=/trunk/; revision=28037
This commit is contained in:
parent
c5eb377a58
commit
a629f387b9
1 changed files with 22 additions and 16 deletions
|
@ -1239,16 +1239,19 @@ CallWindowProcA(WNDPROC lpPrevWndFunc,
|
||||||
if (lpPrevWndFunc == NULL)
|
if (lpPrevWndFunc == NULL)
|
||||||
lpPrevWndFunc = (WNDPROC)NtUserGetWindowLong(hWnd, GWLP_WNDPROC, TRUE);
|
lpPrevWndFunc = (WNDPROC)NtUserGetWindowLong(hWnd, GWLP_WNDPROC, TRUE);
|
||||||
|
|
||||||
if (!IsCallProcHandle(lpPrevWndFunc) ||
|
if (!IsCallProcHandle(lpPrevWndFunc))
|
||||||
!NtUserDereferenceWndProcHandle((HANDLE)lpPrevWndFunc,
|
return IntCallWindowProcA(TRUE, lpPrevWndFunc, hWnd, Msg, wParam, lParam);
|
||||||
&wpInfo))
|
|
||||||
{
|
|
||||||
return IntCallWindowProcA(TRUE, lpPrevWndFunc, hWnd, Msg, wParam, lParam);
|
|
||||||
}
|
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
return IntCallWindowProcA(!wpInfo.IsUnicode, wpInfo.WindowProc,
|
if (NtUserDereferenceWndProcHandle((HANDLE)lpPrevWndFunc,
|
||||||
hWnd, Msg, wParam, lParam);
|
&wpInfo))
|
||||||
|
return IntCallWindowProcA(!wpInfo.IsUnicode, wpInfo.WindowProc,
|
||||||
|
hWnd, Msg, wParam, lParam);
|
||||||
|
else
|
||||||
|
{
|
||||||
|
DPRINT("CallWindowProcA: can not dereference WndProcHandle\n");
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
@ -1269,17 +1272,20 @@ CallWindowProcW(WNDPROC lpPrevWndFunc,
|
||||||
if (lpPrevWndFunc == NULL)
|
if (lpPrevWndFunc == NULL)
|
||||||
lpPrevWndFunc = (WNDPROC)NtUserGetWindowLong(hWnd, GWLP_WNDPROC, FALSE);
|
lpPrevWndFunc = (WNDPROC)NtUserGetWindowLong(hWnd, GWLP_WNDPROC, FALSE);
|
||||||
|
|
||||||
if (!IsCallProcHandle(lpPrevWndFunc) ||
|
if (!IsCallProcHandle(lpPrevWndFunc))
|
||||||
!NtUserDereferenceWndProcHandle((HANDLE)lpPrevWndFunc,
|
return IntCallWindowProcW(FALSE, lpPrevWndFunc, hWnd, Msg, wParam, lParam);
|
||||||
&wpInfo))
|
|
||||||
{
|
|
||||||
return IntCallWindowProcW(FALSE, lpPrevWndFunc, hWnd, Msg, wParam, lParam);
|
|
||||||
}
|
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
if (NtUserDereferenceWndProcHandle((HANDLE)lpPrevWndFunc,
|
||||||
|
&wpInfo))
|
||||||
return IntCallWindowProcW(!wpInfo.IsUnicode, wpInfo.WindowProc,
|
return IntCallWindowProcW(!wpInfo.IsUnicode, wpInfo.WindowProc,
|
||||||
hWnd, Msg, wParam, lParam);
|
hWnd, Msg, wParam, lParam);
|
||||||
}
|
else
|
||||||
|
{
|
||||||
|
DPRINT("CallWindowProcW: can not dereference WndProcHandle\n");
|
||||||
|
return 0;
|
||||||
|
}
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
|
Loading…
Reference in a new issue