Bug 625060: Make sure XRE_ShutdownChildProcess() actually does that on mac. r=bent a=b

--HG--
extra : rebase_source : b19e92d6a4f8300c19340b60936f63d58b9e9935
This commit is contained in:
Chris Jones 2011-02-01 13:53:53 -06:00
Родитель a7284fdc02
Коммит bb406b0002
1 изменённых файлов: 11 добавлений и 1 удалений

Просмотреть файл

@ -700,6 +700,16 @@ XRE_ShutdownChildProcess()
// (4) ProcessChild joins the IO thread
// (5) exit()
MessageLoop::current()->Quit();
#if defined(XP_MACOSX)
nsCOMPtr<nsIAppShell> appShell(do_GetService(kAppShellCID));
if (appShell) {
// On Mac, we might be only above nsAppShell::Run(), not
// MessagePump::Run(). See XRE_RunAppShell(). To account for
// that case, we fire off an Exit() here. If we were indeed
// above MessagePump::Run(), this Exit() is just superfluous.
appShell->Exit();
}
#endif // XP_MACOSX
}
namespace {