diff options
author | Steven Bennetts <steve@lindenlab.com> | 2008-05-11 20:56:42 +0000 |
---|---|---|
committer | Steven Bennetts <steve@lindenlab.com> | 2008-05-11 20:56:42 +0000 |
commit | 875606a04d656ef6e5600a3a7fb6e8b52feb1945 (patch) | |
tree | 7189f1cd0a2b043446e6f145cb9c72b3a1f125aa /indra/llwindow | |
parent | 783e05058c5d74984ab554fdc60aa06839b9b5c9 (diff) |
QAR-566 maint-viewer-5-merge-2
Effective merge: release@84102 maint-viewer-5@86348 -> maint-viewer-5-merge-2
Actual merge maint-viewer-5-merge-2 -r 87239 : 87246 -> release
Diffstat (limited to 'indra/llwindow')
-rw-r--r-- | indra/llwindow/llwindowmacosx-objc.mm | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/indra/llwindow/llwindowmacosx-objc.mm b/indra/llwindow/llwindowmacosx-objc.mm index b68ea8ef8f..59b25e1726 100644 --- a/indra/llwindow/llwindowmacosx-objc.mm +++ b/indra/llwindow/llwindowmacosx-objc.mm @@ -47,6 +47,8 @@ void setupCocoa() if(!inited) { + NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; + // This is a bit of voodoo taken from the Apple sample code "CarbonCocoa_PictureCursor": // http://developer.apple.com/samplecode/CarbonCocoa_PictureCursor/index.html @@ -55,6 +57,8 @@ void setupCocoa() // Must first call [[[NSWindow alloc] init] release] to get the NSWindow machinery set up so that NSCursor can use a window to cache the cursor image [[[NSWindow alloc] init] release]; + + [pool release]; } } @@ -82,8 +86,10 @@ OSErr releaseImageCursor(CursorRef ref) { if( ref != NULL ) { + NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; NSCursor *cursor = (NSCursor*)ref; [cursor release]; + [pool release]; } else { @@ -97,8 +103,10 @@ OSErr setImageCursor(CursorRef ref) { if( ref != NULL ) { + NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init]; NSCursor *cursor = (NSCursor*)ref; [cursor set]; + [pool release]; } else { |