Author: greatlrd
Date: Sat Dec 2 19:57:21 2006
New Revision: 25017
URL:
http://svn.reactos.org/svn/reactos?rev=25017&view=rev
Log:
Fixed follow bug Create_DirectDraw
1. did not set the DDRAWILCL_DIRECTDRAW7 to This->lpLcl->dwLocalFlags
2. did not initate the This->lpLcl->dwLocalRefCnt to 0 and Main_DDrawSurface_AddRef
did wrong count then
Modified:
trunk/reactos/dll/directx/ddraw/startup.c
Modified: trunk/reactos/dll/directx/ddraw/startup.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/directx/ddraw/startup.…
==============================================================================
--- trunk/reactos/dll/directx/ddraw/startup.c (original)
+++ trunk/reactos/dll/directx/ddraw/startup.c Sat Dec 2 19:57:21 2006
@@ -889,7 +889,6 @@
return DDERR_INVALIDDIRECTDRAWGUID;
}
-
if (This == NULL)
{
/* We do not have any DirectDraw interface alloc */
@@ -919,8 +918,10 @@
/* FIXME cleanup */
return DDERR_OUTOFMEMORY;
}
-
+
This->lpLcl->lpGbl = &ddgbl;
+ This->lpLcl->dwLocalRefCnt = 0;
+ This->lpLcl->dwLocalFlags = DDRAWILCL_DIRECTDRAW7;
*pIface = (LPDIRECTDRAW)This;
@@ -928,7 +929,7 @@
{
return DDERR_INVALIDPARAMS;
}
-
+
if (StartDirectDraw((LPDIRECTDRAW*)This, pGUID) == DD_OK);
{