mirror of
https://gitlab.winehq.org/wine/wine-gecko.git
synced 2024-09-13 09:24:08 -07:00
Bug 1139860 - Fix xpcshell content process timeout crashes (r=jimm)
This commit is contained in:
parent
b565dea114
commit
f25a5541e1
@ -2189,7 +2189,7 @@ ContentParent::StartForceKillTimer()
|
|||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
||||||
int32_t timeoutSecs = Preferences::GetInt("dom.ipc.tabs.shutdownTimeoutSecs", 0);
|
int32_t timeoutSecs = Preferences::GetInt("dom.ipc.tabs.shutdownTimeoutSecs", 5);
|
||||||
if (timeoutSecs > 0) {
|
if (timeoutSecs > 0) {
|
||||||
mForceKillTimer = do_CreateInstance("@mozilla.org/timer;1");
|
mForceKillTimer = do_CreateInstance("@mozilla.org/timer;1");
|
||||||
MOZ_ASSERT(mForceKillTimer);
|
MOZ_ASSERT(mForceKillTimer);
|
||||||
@ -3471,6 +3471,14 @@ ContentParent::DeallocPRemoteSpellcheckEngineParent(PRemoteSpellcheckEngineParen
|
|||||||
/* static */ void
|
/* static */ void
|
||||||
ContentParent::ForceKillTimerCallback(nsITimer* aTimer, void* aClosure)
|
ContentParent::ForceKillTimerCallback(nsITimer* aTimer, void* aClosure)
|
||||||
{
|
{
|
||||||
|
#ifdef ENABLE_TESTS
|
||||||
|
// We don't want to time out the content process during XPCShell tests. This
|
||||||
|
// is the easiest way to ensure that.
|
||||||
|
if (PR_GetEnv("XPCSHELL_TEST_PROFILE_DIR")) {
|
||||||
|
return;
|
||||||
|
}
|
||||||
|
#endif
|
||||||
|
|
||||||
auto self = static_cast<ContentParent*>(aClosure);
|
auto self = static_cast<ContentParent*>(aClosure);
|
||||||
self->KillHard("ShutDownKill");
|
self->KillHard("ShutDownKill");
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user