From: <md...@us...> - 2011-01-08 06:56:48
|
Revision: 8901 http://matplotlib.svn.sourceforge.net/matplotlib/?rev=8901&view=rev Author: mdehoon Date: 2011-01-08 06:56:42 +0000 (Sat, 08 Jan 2011) Log Message: ----------- Fixing a bug. Due to a race condition, the view of a closing window could get one release too many. Modified Paths: -------------- trunk/matplotlib/src/_macosx.m Modified: trunk/matplotlib/src/_macosx.m =================================================================== --- trunk/matplotlib/src/_macosx.m 2011-01-06 19:55:16 UTC (rev 8900) +++ trunk/matplotlib/src/_macosx.m 2011-01-08 06:56:42 UTC (rev 8901) @@ -3755,7 +3755,6 @@ [window setDelegate: view]; [window makeFirstResponder: view]; [[window contentView] addSubview: view]; - [view release]; [window makeKeyAndOrderFront: nil]; nwin++; @@ -4854,6 +4853,10 @@ gstate = PyGILState_Ensure(); Py_DECREF(manager); PyGILState_Release(gstate); + /* The reference count of the view that was added as a subview to the + * content view of this window was increased during the call to addSubview, + * and is decreased during the call to [super dealloc]. + */ [super dealloc]; } @end This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |