mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-17 15:25:52 +00:00
Bug 1431079 - Ensure we don't attempt to launch content processes during shutdown. r=smaug
This commit is contained in:
parent
24eb731836
commit
83aecd3510
@ -601,6 +601,14 @@ public:
|
||||
nullptr);
|
||||
}
|
||||
|
||||
// But starting a process can failure for any number of reasons. Reject the
|
||||
// promise if we could not.
|
||||
if (!targetProcess) {
|
||||
mPromise->Reject(NS_ERROR_ABORT, __func__);
|
||||
mPromise = nullptr;
|
||||
return NS_OK;
|
||||
}
|
||||
|
||||
ClientOpenWindowOpParent* actor =
|
||||
new ClientOpenWindowOpParent(mArgs, mPromise);
|
||||
|
||||
|
@ -1989,6 +1989,11 @@ ContentParent::LaunchSubprocess(ProcessPriority aInitialPriority /* = PROCESS_PR
|
||||
{
|
||||
AUTO_PROFILER_LABEL("ContentParent::LaunchSubprocess", OTHER);
|
||||
|
||||
if (!ContentProcessManager::GetSingleton()) {
|
||||
// Shutdown has begun, we shouldn't spawn any more child processes.
|
||||
return false;
|
||||
}
|
||||
|
||||
std::vector<std::string> extraArgs;
|
||||
extraArgs.push_back("-childID");
|
||||
char idStr[21];
|
||||
|
Loading…
Reference in New Issue
Block a user