Author: greatlrd
Date: Sat Dec 2 22:26:55 2006
New Revision: 25019
URL:
http://svn.reactos.org/svn/reactos?rev=25019&view=rev
Log:
fixed so only NULL and DDCREATE_HARDWAREONLY are accpect when you linking two directdraw
interface.
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 22:26:55 2006
@@ -912,12 +912,24 @@
else
{
/* We got the DirectDraw interface alloc and we need create the link */
- LPDDRAWI_DIRECTDRAW_INT newThis;
+
+ LPDDRAWI_DIRECTDRAW_INT newThis;
newThis = DxHeapMemAlloc(sizeof(DDRAWI_DIRECTDRAW_INT));
if (newThis == NULL)
{
return DDERR_OUTOFMEMORY;
}
+
+ /* we need check the GUID lpGUID what type it is */
+ if (pGUID != DDCREATE_HARDWAREONLY)
+ {
+ if (pGUID !=NULL)
+ {
+ This = newThis;
+ return DDERR_INVALIDDIRECTDRAWGUID;
+ }
+ }
+
newThis->lpLink = This;
This = newThis;
}