Author: greatlrd Date: Sat Dec 15 23:53:33 2007 New Revision: 31258
URL: http://svn.reactos.org/svn/reactos?rev=31258&view=rev Log: Do not create a surface from wrong process. if we found it was another process try call on createsurface that have started ddraw it will fail.
Modified: trunk/reactos/dll/directx/ddraw/Surface/createsurface.c
Modified: trunk/reactos/dll/directx/ddraw/Surface/createsurface.c URL: http://svn.reactos.org/svn/reactos/trunk/reactos/dll/directx/ddraw/Surface/c... ============================================================================== --- trunk/reactos/dll/directx/ddraw/Surface/createsurface.c (original) +++ trunk/reactos/dll/directx/ddraw/Surface/createsurface.c Sat Dec 15 23:53:33 2007 @@ -54,6 +54,10 @@ { return DDERR_INVALIDPARAMS; } + if (pDDraw->lpLcl->dwProcessId != GetCurrentProcessId() ) + { + return DDERR_INVALIDOBJECT; + }
if(!(pDDSD->dwFlags & DDSD_HEIGHT) && !(pDDSD->dwFlags & DDSD_HEIGHT) && !(pDDSD->ddsCaps.dwCaps & DDSCAPS_PRIMARYSURFACE))