Fixed double-free of the window shape path
authorSam Lantinga <slouken@libsdl.org>
Sat, 23 Nov 2013 02:02:29 -0800
changeset 8023 7e9b97eb8aa3
parent 8022 7396e3cc5337
child 8024 ffbdb99af7bd
Fixed double-free of the window shape path
src/video/cocoa/SDL_cocoashape.m
--- a/src/video/cocoa/SDL_cocoashape.m	Fri Nov 22 14:19:52 2013 -0300
+++ b/src/video/cocoa/SDL_cocoashape.m	Sat Nov 23 02:02:29 2013 -0800
@@ -92,7 +92,7 @@
 
     pool = [[NSAutoreleasePool alloc] init];
     closure.view = [windata->nswindow contentView];
-    closure.path = [[NSBezierPath bezierPath] autorelease];
+    closure.path = [[NSBezierPath bezierPath] init];
     closure.window = shaper->window;
     SDL_TraverseShapeTree(data->shape,&ConvertRects,&closure);
     [closure.path addClip];