Author: jgardou
Date: Wed Sep 17 11:40:21 2014
New Revision: 64178
URL:
http://svn.reactos.org/svn/reactos?rev=64178&view=rev
Log:
[WIN32K]
- Fix user-mode region attribute handling in IntGdiSetRegionOwner.
Modified:
trunk/reactos/win32ss/gdi/ntgdi/region.c
Modified: trunk/reactos/win32ss/gdi/ntgdi/region.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/win32ss/gdi/ntgdi/region.c…
==============================================================================
--- trunk/reactos/win32ss/gdi/ntgdi/region.c [iso-8859-1] (original)
+++ trunk/reactos/win32ss/gdi/ntgdi/region.c [iso-8859-1] Wed Sep 17 11:40:21 2014
@@ -2323,23 +2323,22 @@
PRGN_ATTR prgnattr;
PPROCESSINFO ppi;
- prgn = REGION_LockRgn(hRgn);
+ prgn = RGNOBJAPI_Lock(hRgn, &prgnattr);
if (!prgn)
{
return FALSE;
}
- prgnattr = GDIOBJ_pvGetObjectAttr(&prgn->BaseObject);
- if (prgnattr)
+ if (prgnattr != &prgn->rgnattr)
{
GDIOBJ_vSetObjectAttr(&prgn->BaseObject, NULL);
- prgn->prgnattr = NULL;
+ prgn->prgnattr = &prgn->rgnattr;
ppi = PsGetCurrentProcessWin32Process();
GdiPoolFree(ppi->pPoolRgnAttr, prgnattr);
}
RGNOBJAPI_Unlock(prgn);
- return GreSetObjectOwner(hRgn, OwnerMask);
+ return GreSetObjectOwner(hRgn, OwnerMask);
}
INT