Fix a stupied bug in DdAttachSurface when pSurfaceFrom->hDDSurface is NULL or pSurfaceTo->hDDSurface is null we need create them.

svn path=/trunk/; revision=29202
This commit is contained in:
Magnus Olsen 2007-09-25 16:49:13 +00:00
parent 27a27ff89e
commit 588e62a967

View file

@ -942,7 +942,7 @@ DdAttachSurface( LPDDRAWI_DDRAWSURFACE_LCL pSurfaceFrom,
LPDDRAWI_DDRAWSURFACE_LCL pSurfaceTo)
{
/* Create Surface if it does not exits one */
if (pSurfaceFrom->hDDSurface)
if (!pSurfaceFrom->hDDSurface)
{
if (!bDDCreateSurface(pSurfaceFrom, FALSE))
{
@ -951,7 +951,7 @@ DdAttachSurface( LPDDRAWI_DDRAWSURFACE_LCL pSurfaceFrom,
}
/* Create Surface if it does not exits one */
if (pSurfaceTo->hDDSurface)
if (!pSurfaceTo->hDDSurface)
{
if (!bDDCreateSurface(pSurfaceTo, FALSE))
{