Memory leak fix for DirectX software surfaces
authorSam Lantinga <slouken@libsdl.org>
Wed, 03 Jul 2002 04:54:55 +0000
changeset 422 b1b9ee41be70
parent 421 195dd37b3d86
child 423 d1565c52ded5
Memory leak fix for DirectX software surfaces
src/video/SDL_surface.c
--- a/src/video/SDL_surface.c	Tue Jul 02 04:07:01 2002 +0000
+++ b/src/video/SDL_surface.c	Wed Jul 03 04:54:55 2002 +0000
@@ -812,7 +812,7 @@
 		SDL_FreeBlitMap(surface->map);
 		surface->map = NULL;
 	}
-	if ( (surface->flags & SDL_HWSURFACE) == SDL_HWSURFACE ) {
+	if ( surface->hwdata ) {
 		SDL_VideoDevice *video = current_video;
 		SDL_VideoDevice *this  = current_video;
 		video->FreeHWSurface(this, surface);