Mercurial > sdl-ios-xcode
comparison src/video/SDL_surface.c @ 5261:bbdf9250ee8b
Removed unused leak detection code.
author | Sam Lantinga <slouken@libsdl.org> |
---|---|
date | Fri, 11 Feb 2011 14:23:22 -0800 |
parents | d976b67150c5 |
children | f26314c20071 |
comparison
equal
deleted
inserted
replaced
5260:b0f5108fda60 | 5261:bbdf9250ee8b |
---|---|
143 SDL_SetSurfaceBlendMode(surface, SDL_BLENDMODE_BLEND); | 143 SDL_SetSurfaceBlendMode(surface, SDL_BLENDMODE_BLEND); |
144 } | 144 } |
145 | 145 |
146 /* The surface is ready to go */ | 146 /* The surface is ready to go */ |
147 surface->refcount = 1; | 147 surface->refcount = 1; |
148 #ifdef CHECK_LEAKS | |
149 ++surfaces_allocated; | |
150 #endif | |
151 return surface; | 148 return surface; |
152 } | 149 } |
153 | 150 |
154 /* | 151 /* |
155 * Create an RGB surface from an existing memory buffer | 152 * Create an RGB surface from an existing memory buffer |
929 } | 926 } |
930 if (surface->pixels && ((surface->flags & SDL_PREALLOC) != SDL_PREALLOC)) { | 927 if (surface->pixels && ((surface->flags & SDL_PREALLOC) != SDL_PREALLOC)) { |
931 SDL_free(surface->pixels); | 928 SDL_free(surface->pixels); |
932 } | 929 } |
933 SDL_free(surface); | 930 SDL_free(surface); |
934 #ifdef CHECK_LEAKS | |
935 --surfaces_allocated; | |
936 #endif | |
937 } | 931 } |
938 | 932 |
939 /* vi: set ts=4 sw=4 expandtab: */ | 933 /* vi: set ts=4 sw=4 expandtab: */ |