mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 13:21:05 +00:00
Bug 1248695 - Check for null browser app object when handling UI telemetry events; r=snorp
The nsAppShell mBrowserApp object may not have been initialized when handling UI telemetry events. In that case, we should bail instead of crashing.
This commit is contained in:
parent
a44d38701c
commit
f0b94011a2
@ -655,6 +655,8 @@ nsAppShell::LegacyGeckoEvent::Run()
|
||||
}
|
||||
|
||||
case AndroidGeckoEvent::TELEMETRY_UI_SESSION_STOP: {
|
||||
if (!nsAppShell::Get()->mBrowserApp)
|
||||
break;
|
||||
if (curEvent->Characters().Length() == 0)
|
||||
break;
|
||||
|
||||
@ -672,6 +674,8 @@ nsAppShell::LegacyGeckoEvent::Run()
|
||||
}
|
||||
|
||||
case AndroidGeckoEvent::TELEMETRY_UI_SESSION_START: {
|
||||
if (!nsAppShell::Get()->mBrowserApp)
|
||||
break;
|
||||
if (curEvent->Characters().Length() == 0)
|
||||
break;
|
||||
|
||||
@ -688,6 +692,8 @@ nsAppShell::LegacyGeckoEvent::Run()
|
||||
}
|
||||
|
||||
case AndroidGeckoEvent::TELEMETRY_UI_EVENT: {
|
||||
if (!nsAppShell::Get()->mBrowserApp)
|
||||
break;
|
||||
if (curEvent->Data().Length() == 0)
|
||||
break;
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user