Author: tkreuzer
Date: Sun Mar 4 18:48:48 2012
New Revision: 56004
URL:
http://svn.reactos.org/svn/reactos?rev=56004&view=rev
Log:
[WIN32K]
- Fix reference leaks in EngAssociateSurface and EngModifySurface
Modified:
branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/eng/surface.c
Modified: branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/eng/surface.c
URL:
http://svn.reactos.org/svn/reactos/branches/GSoC_2011/GdiFontDriver/subsyst…
==============================================================================
--- branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/eng/surface.c [iso-8859-1]
(original)
+++ branches/GSoC_2011/GdiFontDriver/subsystems/win32/win32k/eng/surface.c [iso-8859-1]
Sun Mar 4 18:48:48 2012
@@ -388,7 +388,8 @@
psurf->flags &= ~HOOK_FLAGS;
psurf->flags |= (flHooks & HOOK_FLAGS);
- /* Get palette */
+ /* Get new palette */
+ if (psurf->ppal) PALETTE_ShareUnlockPalette(psurf->ppal);
psurf->ppal = PALETTE_ShareLockPalette(ppdev->devinfo.hpalDefault);
SURFACE_ShareUnlockSurface(psurf);
@@ -432,7 +433,8 @@
psurf->flags &= ~HOOK_FLAGS;
psurf->flags |= (flHooks & HOOK_FLAGS);
- /* Get palette */
+ /* Get new palette */
+ if (psurf->ppal) PALETTE_ShareUnlockPalette(psurf->ppal);
psurf->ppal = PALETTE_ShareLockPalette(ppdev->devinfo.hpalDefault);
SURFACE_ShareUnlockSurface(psurf);