comparison src/video/SDL_surface.c @ 915:01cddd0f2efb

You can't free locked surfaces!
author Sam Lantinga <slouken@libsdl.org>
date Sun, 25 Jul 2004 18:43:07 +0000
parents 333db1d87876
children bb1588ebe47b
comparison
equal deleted inserted replaced
914:bbf8dcc8aed6 915:01cddd0f2efb
899 return; 899 return;
900 } 900 }
901 if ( --surface->refcount > 0 ) { 901 if ( --surface->refcount > 0 ) {
902 return; 902 return;
903 } 903 }
904 while ( surface->locked > 0 ) {
905 SDL_UnlockSurface(surface);
906 }
904 if ( (surface->flags & SDL_RLEACCEL) == SDL_RLEACCEL ) { 907 if ( (surface->flags & SDL_RLEACCEL) == SDL_RLEACCEL ) {
905 SDL_UnRLESurface(surface, 0); 908 SDL_UnRLESurface(surface, 0);
906 } 909 }
907 if ( surface->format ) { 910 if ( surface->format ) {
908 SDL_FreeFormat(surface->format); 911 SDL_FreeFormat(surface->format);