- Delete region on error path.
[WIN32SS]
 - Improve/add a few debug prints.

svn path=/trunk/; revision=64182
This commit is contained in:
Jérôme Gardou 2014-09-17 15:08:23 +00:00
parent 65581fedb3
commit 07607739ca
3 changed files with 11 additions and 1 deletions

View file

@ -1037,7 +1037,8 @@ NtUserGetDCEx(HWND hWnd OPTIONAL, HANDLE ClipRegion, ULONG Flags)
PWND Wnd=NULL;
DECLARE_RETURN(HDC);
TRACE("Enter NtUserGetDCEx\n");
TRACE("Enter NtUserGetDCEx: hWnd %p, ClipRegion %p, Flags %x.\n",
hWnd, ClipRegion, Flags);
UserEnterExclusive();
if (hWnd && !(Wnd = UserGetWindowObject(hWnd)))

View file

@ -1619,6 +1619,9 @@ IntCallWindowProcA(BOOL IsAnsiProc,
LRESULT Result = 0, PreResult = 0;
DWORD Data = 0;
TRACE("IntCallWindowProcA: IsAnsiProc : %s, WndProc %p, pWnd %p, hWnd %p, Msg %u, wParam %Iu, lParam %Iu.\n",
IsAnsiProc ? "TRUE" : "FALSE", WndProc, pWnd, hWnd, Msg, wParam, lParam);
if (WndProc == NULL)
{
WARN("IntCallWindowsProcA() called with WndProc = NULL!\n");

View file

@ -281,9 +281,15 @@ DefWndNCPaint(HWND hWnd, HRGN hRgn, BOOL Active)
Style = GetWindowLongPtrW(hWnd, GWL_STYLE);
TRACE("DefWndNCPaint: hWnd %p, hRgn %p, Active %s.\n",
hWnd, hRgn, Active ? "TRUE" : "FALSE");
hDC = GetDCEx(hWnd, hRgn, DCX_WINDOW | DCX_INTERSECTRGN | DCX_USESTYLE | DCX_KEEPCLIPRGN);
if (hDC == 0)
{
ERR("hDC is NULL!\n");
if (hRgn != HRGN_WINDOW)
DeleteObject(hRgn);
return 0;
}