From 2465c878441961e5d84e224436ad92c2b4b4da91 Mon Sep 17 00:00:00 2001 From: "C.W. Betts" Date: Mon, 23 Sep 2013 01:12:36 -0600 Subject: [PATCH] Fix overreleasing in Cocoa code --- BBGE/Cocoa.mm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/BBGE/Cocoa.mm b/BBGE/Cocoa.mm index 102b2bc..6a90e74 100644 --- a/BBGE/Cocoa.mm +++ b/BBGE/Cocoa.mm @@ -11,10 +11,10 @@ void cocoaMessageBox(const std::string &title, const std::string &msg) { + @autoreleasepool { NSString *nstitle = [NSString stringWithUTF8String:title.c_str()]; NSString *nsmsg = [NSString stringWithUTF8String:msg.c_str()]; - NSRunAlertPanel(nstitle, nsmsg, @"OK", nil, nil); - [nsmsg release]; - [nstitle release]; + NSRunAlertPanel(nstitle, nsmsg, nil, nil, nil); + } }