Author: greatlrd Date: Sun Dec 16 03:38:22 2007 New Revision: 31266
URL: http://svn.reactos.org/svn/reactos?rev=31266&view=rev Log: fix another bug in createsurface a program does not need set the flag DDSD_LPSURFACE, if they forget ddraw will automatic set it.
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 Sun Dec 16 03:38:22 2007 @@ -76,6 +76,16 @@ return DDERR_INVALIDPARAMS; }
+ /* + * program does not need set the DDSD_LPSURFACE, + * if they forget set it, the ddraw will autoamtic set it. + * + */ + if ((pDDSD->dwFlags & DDSD_LPSURFACE) != DDSD_LPSURFACE) + { + pDDSD->dwFlags = pDDSD->dwFlags | DDSD_LPSURFACE; + } + /* FIXME count our how many surface we need */
DxHeapMemAlloc(slist_int, num_of_surf * sizeof( LPDDRAWI_DDRAWSURFACE_INT ) );