cocoaTouch/SDLOverrides/SDL_uikitappdelegate.m
changeset 2701 3a8560c00f78
parent 2699 249adefa9c1c
child 2702 48fc46a922fd
--- a/cocoaTouch/SDLOverrides/SDL_uikitappdelegate.m	Wed Jan 20 14:31:45 2010 +0000
+++ b/cocoaTouch/SDLOverrides/SDL_uikitappdelegate.m	Sat Jan 23 13:15:27 2010 +0000
@@ -63,7 +63,6 @@
 }
 
 -(IBAction) startSDLgame {
-	
 	[setup startThread:@"engineProtocol"];
 	[setup loadSettingsFromFile:@"settings.plist" forKey:@"systemSettings"];
 
@@ -76,10 +75,13 @@
 
 	NSLog(@"Game is launching...");
 
+	NSAutoreleasePool *internal_pool = [[NSAutoreleasePool alloc] init];
+
 	// direct execution or thread? check the one that gives most fps
 	// library or call SDL_main? pascal quits at the end of the main
 	Game();
-	
+
+	[internal_pool drain];
 	NSLog(@"Game is exting...");
 
 	[[window viewWithTag:54867] removeFromSuperview];