Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.blender.org/blender.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
path: root/intern
diff options
context:
space:
mode:
authorBrecht Van Lommel <brechtvanlommel@pandora.be>2011-05-23 19:56:26 +0400
committerBrecht Van Lommel <brechtvanlommel@pandora.be>2011-05-23 19:56:26 +0400
commit1e00590f1c2f8d98ed52f8e12d70723165edc9d3 (patch)
tree2ec066bf1802cc0a24bde4444ef305e447759369 /intern
parent6357b126413db0a66e820a36083de59db66cfb00 (diff)
Fix #26728: crash with load/save on Mac, on files that close & open a window
when loading them. Custom cursor shown during load was not freed correctly when closing the old window, which resulted in unpredictable crashes later on.
Diffstat (limited to 'intern')
-rw-r--r--intern/ghost/intern/GHOST_WindowCocoa.mm8
1 files changed, 6 insertions, 2 deletions
diff --git a/intern/ghost/intern/GHOST_WindowCocoa.mm b/intern/ghost/intern/GHOST_WindowCocoa.mm
index 8d28c9d5b17..fb7d4a459c7 100644
--- a/intern/ghost/intern/GHOST_WindowCocoa.mm
+++ b/intern/ghost/intern/GHOST_WindowCocoa.mm
@@ -461,9 +461,13 @@ GHOST_WindowCocoa::GHOST_WindowCocoa(
GHOST_WindowCocoa::~GHOST_WindowCocoa()
{
- if (m_customCursor) delete m_customCursor;
-
NSAutoreleasePool *pool = [[NSAutoreleasePool alloc] init];
+
+ if (m_customCursor) {
+ [m_customCursor release];
+ m_customCursor = nil;
+ }
+
[m_openGLView release];
if (m_window) {