summaryrefslogtreecommitdiffstats
path: root/macosx/tkMacOSXInit.c
diff options
context:
space:
mode:
authorKevin Walzer <kw@codebykevin.com>2015-12-07 02:04:45 (GMT)
committerKevin Walzer <kw@codebykevin.com>2015-12-07 02:04:45 (GMT)
commite82200cb0ca4389ea75f8ae0c2096358a985c14e (patch)
tree91a16332713cfc52d7f400a64513ff1e5646cd35 /macosx/tkMacOSXInit.c
parent7f2c3a3f39d6a76f0656cbffc7e589b1a59bc346 (diff)
downloadtk-e82200cb0ca4389ea75f8ae0c2096358a985c14e.zip
tk-e82200cb0ca4389ea75f8ae0c2096358a985c14e.tar.gz
tk-e82200cb0ca4389ea75f8ae0c2096358a985c14e.tar.bz2
Fix for zombie windows on El Capitan/OS X 10.11; thanks to Marc Culler for patch
Diffstat (limited to 'macosx/tkMacOSXInit.c')
-rw-r--r--macosx/tkMacOSXInit.c6
1 files changed, 1 insertions, 5 deletions
diff --git a/macosx/tkMacOSXInit.c b/macosx/tkMacOSXInit.c
index 6ba726d..8e5479e 100644
--- a/macosx/tkMacOSXInit.c
+++ b/macosx/tkMacOSXInit.c
@@ -242,10 +242,7 @@ TkpInit(
}
#endif
- static NSAutoreleasePool *pool = nil;
- if (!pool) {
- pool = [NSAutoreleasePool new];
- }
+ NSAutoreleasePool *pool = [NSAutoreleasePool new];
[[NSUserDefaults standardUserDefaults] registerDefaults:
[NSDictionary dictionaryWithObjectsAndKeys:
[NSNumber numberWithBool:YES],
@@ -316,7 +313,6 @@ TkpInit(
TkMacOSXUseAntialiasedText(interp, -1);
TkMacOSXInitCGDrawing(interp, TRUE, 0);
[pool drain];
- pool = [NSAutoreleasePool new];
/*
* FIXME: Close stdin & stdout for remote debugging otherwise we will