summaryrefslogtreecommitdiffstats
path: root/macosx
diff options
context:
space:
mode:
authordynaflash <[email protected]>2008-02-21 13:20:21 +0000
committerdynaflash <[email protected]>2008-02-21 13:20:21 +0000
commit3aa14dbf73e98a3a4bbd091a3b083e4e256bf92f (patch)
tree996d5259fe70700c3ce9687ca70e384588afb06c /macosx
parentcdfc09f2ba0eac2793357e18408248fba1f9620d (diff)
MacGui: Fix issue where canceling the open source window, then re opening it and selecting a source or cancelling is could cause a crash.
- Patch courtesy of Xeri git-svn-id: svn://svn.handbrake.fr/HandBrake/trunk@1308 b64f7644-9d1e-0410-96f1-a4d463321fa5
Diffstat (limited to 'macosx')
-rw-r--r--macosx/Controller.mm4
1 files changed, 2 insertions, 2 deletions
diff --git a/macosx/Controller.mm b/macosx/Controller.mm
index 22d9ebfe4..75c536fbe 100644
--- a/macosx/Controller.mm
+++ b/macosx/Controller.mm
@@ -1053,8 +1053,6 @@ static NSString * ChooseSourceIdentifier = @"Choose Source It
- (void) browseSourcesDone: (NSOpenPanel *) sheet
returnCode: (int) returnCode contextInfo: (void *) contextInfo
{
- [browsedSourceDisplayName release];
-
/* we convert the sender content of contextInfo back into a variable called sender
* mostly just for consistency for evaluation later
*/
@@ -1062,6 +1060,8 @@ static NSString * ChooseSourceIdentifier = @"Choose Source It
/* User selected a file to open */
if( returnCode == NSOKButton )
{
+ /* Free display name allocated previously by this code */
+ [browsedSourceDisplayName release];
NSString *scanPath = [[sheet filenames] objectAtIndex: 0];
/* we set the last searched source directory in the prefs here */