hedgewars/SDLMain.m
branch0.9.14.1
changeset 4336 006133b13b32
parent 3697 d5b30d6373fc
--- a/hedgewars/SDLMain.m	Sun Nov 14 20:37:55 2010 +0100
+++ b/hedgewars/SDLMain.m	Sun Nov 28 01:58:08 2010 +0100
@@ -216,9 +216,11 @@
 #endif /* SDL_USE_CPS */
 
     /* Set up the menubar */
-    [NSApp setMainMenu:[[NSMenu alloc] init]];
+    NSMenu *menu = [[NSMenu alloc] init];
+    [NSApp setMainMenu:menu];
     setApplicationMenu();
     setupWindowMenu();
+    [menu release];
 
     /* Create SDLMain and make it the app delegate */
     sdlMain = [[SDLMain alloc] init];