mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-24 13:21:05 +00:00
Bug 1637888 - Add a null-check for Document passed to PreloaderBase::NotifyRestart
as it is a valid case to happen, r=emilio
Differential Revision: https://phabricator.services.mozilla.com/D75282
This commit is contained in:
parent
bb85ae41b1
commit
3195caba81
@ -146,7 +146,10 @@ void PreloaderBase::NotifyUsage() {
|
||||
|
||||
void PreloaderBase::NotifyRestart(dom::Document* aDocument,
|
||||
PreloaderBase* aNewPreloader) {
|
||||
aDocument->Preloads().DeregisterPreload(&mKey);
|
||||
if (aDocument) {
|
||||
aDocument->Preloads().DeregisterPreload(&mKey);
|
||||
}
|
||||
|
||||
mKey = PreloadHashKey();
|
||||
|
||||
if (aNewPreloader) {
|
||||
|
Loading…
Reference in New Issue
Block a user