# HG changeset patch # User Sam Lantinga # Date 1297463002 28800 # Node ID bbdf9250ee8bbe8a5e1d9dfe44c356db3df2ae75 # Parent b0f5108fda6021def725d39bbee2e8a92f6f238d Removed unused leak detection code. diff -r b0f5108fda60 -r bbdf9250ee8b VisualC/SDL/SDL_VS2005.vcproj --- a/VisualC/SDL/SDL_VS2005.vcproj Fri Feb 11 13:06:35 2011 -0800 +++ b/VisualC/SDL/SDL_VS2005.vcproj Fri Feb 11 14:23:22 2011 -0800 @@ -900,10 +900,6 @@ > - - diff -r b0f5108fda60 -r bbdf9250ee8b VisualC/SDL/SDL_VS2008.vcproj --- a/VisualC/SDL/SDL_VS2008.vcproj Fri Feb 11 13:06:35 2011 -0800 +++ b/VisualC/SDL/SDL_VS2008.vcproj Fri Feb 11 14:23:22 2011 -0800 @@ -915,10 +915,6 @@ > - - diff -r b0f5108fda60 -r bbdf9250ee8b VisualC/SDL/SDL_VS2010.vcxproj --- a/VisualC/SDL/SDL_VS2010.vcxproj Fri Feb 11 13:06:35 2011 -0800 +++ b/VisualC/SDL/SDL_VS2010.vcxproj Fri Feb 11 14:23:22 2011 -0800 @@ -315,7 +315,6 @@ - @@ -467,4 +466,4 @@ - \ No newline at end of file + diff -r b0f5108fda60 -r bbdf9250ee8b Xcode-iPhoneOS/SDL/SDLiPhoneOS.xcodeproj/project.pbxproj --- a/Xcode-iPhoneOS/SDL/SDLiPhoneOS.xcodeproj/project.pbxproj Fri Feb 11 13:06:35 2011 -0800 +++ b/Xcode-iPhoneOS/SDL/SDLiPhoneOS.xcodeproj/project.pbxproj Fri Feb 11 14:23:22 2011 -0800 @@ -226,7 +226,6 @@ FDA684560DF2374E00F98A1A /* SDL_blit_N.c in Sources */ = {isa = PBXBuildFile; fileRef = FDA683090DF2374E00F98A1A /* SDL_blit_N.c */; }; FDA684570DF2374E00F98A1A /* SDL_blit_slow.c in Sources */ = {isa = PBXBuildFile; fileRef = FDA6830A0DF2374E00F98A1A /* SDL_blit_slow.c */; }; FDA684580DF2374E00F98A1A /* SDL_bmp.c in Sources */ = {isa = PBXBuildFile; fileRef = FDA6830B0DF2374E00F98A1A /* SDL_bmp.c */; }; - FDA6845B0DF2374E00F98A1A /* SDL_leaks.h in Headers */ = {isa = PBXBuildFile; fileRef = FDA6830E0DF2374E00F98A1A /* SDL_leaks.h */; }; FDA6845C0DF2374E00F98A1A /* SDL_pixels.c in Sources */ = {isa = PBXBuildFile; fileRef = FDA6830F0DF2374E00F98A1A /* SDL_pixels.c */; }; FDA6845D0DF2374E00F98A1A /* SDL_pixels_c.h in Headers */ = {isa = PBXBuildFile; fileRef = FDA683100DF2374E00F98A1A /* SDL_pixels_c.h */; }; FDA6845E0DF2374E00F98A1A /* SDL_rect.c in Sources */ = {isa = PBXBuildFile; fileRef = FDA683110DF2374E00F98A1A /* SDL_rect.c */; }; @@ -518,7 +517,6 @@ FDA683090DF2374E00F98A1A /* SDL_blit_N.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_blit_N.c; sourceTree = ""; }; FDA6830A0DF2374E00F98A1A /* SDL_blit_slow.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_blit_slow.c; sourceTree = ""; }; FDA6830B0DF2374E00F98A1A /* SDL_bmp.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_bmp.c; sourceTree = ""; }; - FDA6830E0DF2374E00F98A1A /* SDL_leaks.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDL_leaks.h; sourceTree = ""; }; FDA6830F0DF2374E00F98A1A /* SDL_pixels.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_pixels.c; sourceTree = ""; }; FDA683100DF2374E00F98A1A /* SDL_pixels_c.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDL_pixels_c.h; sourceTree = ""; }; FDA683110DF2374E00F98A1A /* SDL_rect.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_rect.c; sourceTree = ""; }; @@ -1142,7 +1140,6 @@ FDA6830B0DF2374E00F98A1A /* SDL_bmp.c */, 044E5FB711E606EB0076F181 /* SDL_clipboard.c */, 0463873E0F0B5B7D0041FD65 /* SDL_fillrect.c */, - FDA6830E0DF2374E00F98A1A /* SDL_leaks.h */, FDA6830F0DF2374E00F98A1A /* SDL_pixels.c */, FDA683100DF2374E00F98A1A /* SDL_pixels_c.h */, FDA683110DF2374E00F98A1A /* SDL_rect.c */, @@ -1213,7 +1210,6 @@ FDA6844E0DF2374E00F98A1A /* SDL_blit.h in Headers */, FDA684530DF2374E00F98A1A /* SDL_blit_auto.h in Headers */, FDA684550DF2374E00F98A1A /* SDL_blit_copy.h in Headers */, - FDA6845B0DF2374E00F98A1A /* SDL_leaks.h in Headers */, FDA6845D0DF2374E00F98A1A /* SDL_pixels_c.h in Headers */, FDA684630DF2374E00F98A1A /* SDL_RLEaccel_c.h in Headers */, FDA684670DF2374E00F98A1A /* SDL_sysvideo.h in Headers */, diff -r b0f5108fda60 -r bbdf9250ee8b Xcode/SDL/SDL.xcodeproj/project.pbxproj --- a/Xcode/SDL/SDL.xcodeproj/project.pbxproj Fri Feb 11 13:06:35 2011 -0800 +++ b/Xcode/SDL/SDL.xcodeproj/project.pbxproj Fri Feb 11 14:23:22 2011 -0800 @@ -287,7 +287,6 @@ 04BD018112E6671800899322 /* SDL_bmp.c in Sources */ = {isa = PBXBuildFile; fileRef = 04BDFF5A12E6671800899322 /* SDL_bmp.c */; }; 04BD018212E6671800899322 /* SDL_clipboard.c in Sources */ = {isa = PBXBuildFile; fileRef = 04BDFF5B12E6671800899322 /* SDL_clipboard.c */; }; 04BD018712E6671800899322 /* SDL_fillrect.c in Sources */ = {isa = PBXBuildFile; fileRef = 04BDFF6012E6671800899322 /* SDL_fillrect.c */; }; - 04BD018B12E6671800899322 /* SDL_leaks.h in Headers */ = {isa = PBXBuildFile; fileRef = 04BDFF6412E6671800899322 /* SDL_leaks.h */; }; 04BD018C12E6671800899322 /* SDL_pixels.c in Sources */ = {isa = PBXBuildFile; fileRef = 04BDFF6512E6671800899322 /* SDL_pixels.c */; }; 04BD018D12E6671800899322 /* SDL_pixels_c.h in Headers */ = {isa = PBXBuildFile; fileRef = 04BDFF6612E6671800899322 /* SDL_pixels_c.h */; }; 04BD018E12E6671800899322 /* SDL_rect.c in Sources */ = {isa = PBXBuildFile; fileRef = 04BDFF6712E6671800899322 /* SDL_rect.c */; }; @@ -472,7 +471,6 @@ 04BD039B12E6671800899322 /* SDL_bmp.c in Sources */ = {isa = PBXBuildFile; fileRef = 04BDFF5A12E6671800899322 /* SDL_bmp.c */; }; 04BD039C12E6671800899322 /* SDL_clipboard.c in Sources */ = {isa = PBXBuildFile; fileRef = 04BDFF5B12E6671800899322 /* SDL_clipboard.c */; }; 04BD03A112E6671800899322 /* SDL_fillrect.c in Sources */ = {isa = PBXBuildFile; fileRef = 04BDFF6012E6671800899322 /* SDL_fillrect.c */; }; - 04BD03A512E6671800899322 /* SDL_leaks.h in Headers */ = {isa = PBXBuildFile; fileRef = 04BDFF6412E6671800899322 /* SDL_leaks.h */; }; 04BD03A612E6671800899322 /* SDL_pixels.c in Sources */ = {isa = PBXBuildFile; fileRef = 04BDFF6512E6671800899322 /* SDL_pixels.c */; }; 04BD03A712E6671800899322 /* SDL_pixels_c.h in Headers */ = {isa = PBXBuildFile; fileRef = 04BDFF6612E6671800899322 /* SDL_pixels_c.h */; }; 04BD03A812E6671800899322 /* SDL_rect.c in Sources */ = {isa = PBXBuildFile; fileRef = 04BDFF6712E6671800899322 /* SDL_rect.c */; }; @@ -841,7 +839,6 @@ 04BDFF5A12E6671800899322 /* SDL_bmp.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_bmp.c; sourceTree = ""; }; 04BDFF5B12E6671800899322 /* SDL_clipboard.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_clipboard.c; sourceTree = ""; }; 04BDFF6012E6671800899322 /* SDL_fillrect.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_fillrect.c; sourceTree = ""; }; - 04BDFF6412E6671800899322 /* SDL_leaks.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDL_leaks.h; sourceTree = ""; }; 04BDFF6512E6671800899322 /* SDL_pixels.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_pixels.c; sourceTree = ""; }; 04BDFF6612E6671800899322 /* SDL_pixels_c.h */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.h; path = SDL_pixels_c.h; sourceTree = ""; }; 04BDFF6712E6671800899322 /* SDL_rect.c */ = {isa = PBXFileReference; fileEncoding = 4; lastKnownFileType = sourcecode.c.c; path = SDL_rect.c; sourceTree = ""; }; @@ -1516,7 +1513,6 @@ 04BDFF5A12E6671800899322 /* SDL_bmp.c */, 04BDFF5B12E6671800899322 /* SDL_clipboard.c */, 04BDFF6012E6671800899322 /* SDL_fillrect.c */, - 04BDFF6412E6671800899322 /* SDL_leaks.h */, 04BDFF6512E6671800899322 /* SDL_pixels.c */, 04BDFF6612E6671800899322 /* SDL_pixels_c.h */, 04BDFF6712E6671800899322 /* SDL_rect.c */, @@ -1885,7 +1881,6 @@ 04BD017B12E6671800899322 /* SDL_blit_auto.h in Headers */, 04BD017D12E6671800899322 /* SDL_blit_copy.h in Headers */, 04BD018012E6671800899322 /* SDL_blit_slow.h in Headers */, - 04BD018B12E6671800899322 /* SDL_leaks.h in Headers */, 04BD018D12E6671800899322 /* SDL_pixels_c.h in Headers */, 04BD019712E6671800899322 /* SDL_RLEaccel_c.h in Headers */, 04BD019912E6671800899322 /* SDL_shape_internals.h in Headers */, @@ -2015,7 +2010,6 @@ 04BD039512E6671800899322 /* SDL_blit_auto.h in Headers */, 04BD039712E6671800899322 /* SDL_blit_copy.h in Headers */, 04BD039A12E6671800899322 /* SDL_blit_slow.h in Headers */, - 04BD03A512E6671800899322 /* SDL_leaks.h in Headers */, 04BD03A712E6671800899322 /* SDL_pixels_c.h in Headers */, 04BD03B112E6671800899322 /* SDL_RLEaccel_c.h in Headers */, 04BD03B312E6671800899322 /* SDL_shape_internals.h in Headers */, diff -r b0f5108fda60 -r bbdf9250ee8b src/video/SDL_leaks.h --- a/src/video/SDL_leaks.h Fri Feb 11 13:06:35 2011 -0800 +++ /dev/null Thu Jan 01 00:00:00 1970 +0000 @@ -1,33 +0,0 @@ -/* - SDL - Simple DirectMedia Layer - Copyright (C) 1997-2010 Sam Lantinga - - This library is free software; you can redistribute it and/or - modify it under the terms of the GNU Lesser General Public - License as published by the Free Software Foundation; either - version 2.1 of the License, or (at your option) any later version. - - This library is distributed in the hope that it will be useful, - but WITHOUT ANY WARRANTY; without even the implied warranty of - MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU - Lesser General Public License for more details. - - You should have received a copy of the GNU Lesser General Public - License along with this library; if not, write to the Free Software - Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA - - Sam Lantinga - slouken@libsdl.org -*/ -#include "SDL_config.h" - -/* Define this if you want surface leak detection code enabled */ -/*#define CHECK_LEAKS*/ - -/* Global variables used to check leaks in code using SDL */ - -#ifdef CHECK_LEAKS -extern int surfaces_allocated; -#endif - -/* vi: set ts=4 sw=4 expandtab: */ diff -r b0f5108fda60 -r bbdf9250ee8b src/video/SDL_surface.c --- a/src/video/SDL_surface.c Fri Feb 11 13:06:35 2011 -0800 +++ b/src/video/SDL_surface.c Fri Feb 11 14:23:22 2011 -0800 @@ -145,9 +145,6 @@ /* The surface is ready to go */ surface->refcount = 1; -#ifdef CHECK_LEAKS - ++surfaces_allocated; -#endif return surface; } @@ -931,9 +928,6 @@ SDL_free(surface->pixels); } SDL_free(surface); -#ifdef CHECK_LEAKS - --surfaces_allocated; -#endif } /* vi: set ts=4 sw=4 expandtab: */