Author: greatlrd
Date: Mon May 8 20:50:33 2006
New Revision: 21853
URL:
http://svn.reactos.ru/svn/reactos?rev=21853&view=rev
Log:
fixing a bug in gdientry3, found it when I wrote the doc
Modified:
trunk/reactos/dll/win32/gdi32/misc/gdientry.c
Modified: trunk/reactos/dll/win32/gdi32/misc/gdientry.c
URL:
http://svn.reactos.ru/svn/reactos/trunk/reactos/dll/win32/gdi32/misc/gdient…
==============================================================================
--- trunk/reactos/dll/win32/gdi32/misc/gdientry.c (original)
+++ trunk/reactos/dll/win32/gdi32/misc/gdientry.c Mon May 8 20:50:33 2006
@@ -144,6 +144,7 @@
STDCALL
DdDeleteDirectDrawObject(LPDDRAWI_DIRECTDRAW_GBL pDirectDrawGlobal)
{
+ BOOL status;
/* if pDirectDrawGlobal->hDD == NULL and pDirectDrawGlobalInternal->hDD == NULL
return false */
@@ -155,8 +156,14 @@
}
return NtGdiDdDeleteDirectDrawObject((HANDLE)pDirectDrawGlobalInternal->hDD);
}
-
- return NtGdiDdDeleteDirectDrawObject((HANDLE)pDirectDrawGlobal->hDD);
+
+ status = NtGdiDdDeleteDirectDrawObject((HANDLE)pDirectDrawGlobal->hDD);
+ if (status == TRUE) && (pDirectDrawGlobalInternal->hDD != NULL)
+ {
+ pDirectDrawGlobalInternal->hDD = NULL;
+ }
+
+ return status;
}
/*