From 87fd2c6cadc9a8c4e3eecaa0d4b03548abca17d9 Mon Sep 17 00:00:00 2001 From: Gregor Schneider Date: Fri, 17 Oct 2008 15:13:27 +0000 Subject: [PATCH] Typo: check for success of newest allocations. svn path=/trunk/; revision=36791 --- reactos/dll/directx/ddraw/Surface/createsurface.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/reactos/dll/directx/ddraw/Surface/createsurface.c b/reactos/dll/directx/ddraw/Surface/createsurface.c index 9ad8ebee0ff..6ffe5e05527 100644 --- a/reactos/dll/directx/ddraw/Surface/createsurface.c +++ b/reactos/dll/directx/ddraw/Surface/createsurface.c @@ -104,7 +104,7 @@ Internal_CreateSurface( LPDDRAWI_DIRECTDRAW_INT pDDraw, LPDDSURFACEDESC2 pDDSD, /* for more easy to free the memory if something goes wrong */ DxHeapMemAlloc(slist_gbl, num_of_surf * sizeof( LPDDRAWI_DDRAWSURFACE_GBL ) ); - if( slist_lcl == NULL ) + if( slist_gbl == NULL ) { DxHeapMemFree(slist_int); return DDERR_OUTOFMEMORY; @@ -112,7 +112,7 @@ Internal_CreateSurface( LPDDRAWI_DIRECTDRAW_INT pDDraw, LPDDSURFACEDESC2 pDDSD, /* for more easy to free the memory if something goes wrong */ DxHeapMemAlloc(slist_more, num_of_surf * sizeof( LPDDRAWI_DDRAWSURFACE_MORE ) ); - if( slist_lcl == NULL ) + if( slist_more == NULL ) { DxHeapMemFree(slist_int); return DDERR_OUTOFMEMORY;