mirror of
https://github.com/cookiengineer/audacity
synced 2025-10-11 00:53:46 +02:00
Bug 1672 - OS window close button crashes Audacity if Screenshot Tools are open. File > Close hides Screenshot tools and then any closure method crashes Audacity.
This commit is contained in:
@@ -109,7 +109,13 @@ void OpenScreenshotTools()
|
||||
|
||||
void CloseScreenshotTools()
|
||||
{
|
||||
mFrame.reset();
|
||||
// The code below looks like a memory leak,
|
||||
// but actually wxWidgets will take care of deleting the
|
||||
// screenshot window, becuase the parent window is
|
||||
// being deleted. So we only need to free up our pointer
|
||||
// to it, not actually delete the underlying object.
|
||||
if( mFrame )
|
||||
mFrame.release();
|
||||
}
|
||||
|
||||
////////////////////////////////////////////////////////////////////////////////
|
||||
|
Reference in New Issue
Block a user