mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
bug 559400 - add local autorelease pool in nsCocoaWindow::SetModal, for startup dialogs. r=josh
This commit is contained in:
parent
1a07188538
commit
cc0b88dd4a
@ -530,6 +530,12 @@ NS_IMETHODIMP nsCocoaWindow::IsVisible(PRBool & aState)
|
||||
|
||||
NS_IMETHODIMP nsCocoaWindow::SetModal(PRBool aState)
|
||||
{
|
||||
// This is used during startup (outside the event loop) when creating
|
||||
// the add-ons compatibility checking dialog and the profile manager UI;
|
||||
// therefore, it needs to provide an autorelease pool to avoid cocoa
|
||||
// objects leaking.
|
||||
nsAutoreleasePool localPool;
|
||||
|
||||
mModal = aState;
|
||||
nsCocoaWindow *aParent = static_cast<nsCocoaWindow*>(mParent);
|
||||
if (aState) {
|
||||
|
Loading…
Reference in New Issue
Block a user