fix: stale renderer process on quit (#32967)

Co-authored-by: Micha Hanselmann <micha.hanselmann@gmail.com>
This commit is contained in:
trop[bot]
2022-02-21 10:26:22 +09:00
committed by GitHub
parent 78c5a2cf4b
commit 6815c823b3

View File

@@ -468,7 +468,8 @@ void ElectronBrowserMainParts::WillRunMainMessageLoop(
std::unique_ptr<base::RunLoop>& run_loop) {
js_env_->OnMessageLoopCreated();
exit_code_ = content::RESULT_CODE_NORMAL_EXIT;
Browser::Get()->SetMainMessageLoopQuitClosure(run_loop->QuitClosure());
Browser::Get()->SetMainMessageLoopQuitClosure(
run_loop->QuitWhenIdleClosure());
}
void ElectronBrowserMainParts::PostCreateMainMessageLoop() {