1
0
Fork 0
mirror of https://github.com/AquariaOSE/Aquaria.git synced 2025-08-09 07:40:21 +00:00

Fix overreleasing in Cocoa code

This commit is contained in:
C.W. Betts 2013-09-23 01:12:36 -06:00
parent c857722213
commit 2465c87844

View file

@ -11,10 +11,10 @@
void cocoaMessageBox(const std::string &title, const std::string &msg) void cocoaMessageBox(const std::string &title, const std::string &msg)
{ {
@autoreleasepool {
NSString *nstitle = [NSString stringWithUTF8String:title.c_str()]; NSString *nstitle = [NSString stringWithUTF8String:title.c_str()];
NSString *nsmsg = [NSString stringWithUTF8String:msg.c_str()]; NSString *nsmsg = [NSString stringWithUTF8String:msg.c_str()];
NSRunAlertPanel(nstitle, nsmsg, @"OK", nil, nil); NSRunAlertPanel(nstitle, nsmsg, nil, nil, nil);
[nsmsg release]; }
[nstitle release];
} }