зеркало из https://github.com/mozilla/gecko-dev.git
Bug 1657231, part 2 - Clear sInitialized when we destroy the singleton url preloader. r=kmag
Some of the entry points into the URL preloader check sInitialized, and only use it if it is true. However, if we're late in shutdown and we've already cleared the singleton for the preloader then our failure to clear the sInitialized flag means we'll recreate the preloader, which is going to fail in various ways. I think this won't help in the case of bug 1656973, because that seems to go through AutoBeginReading, which unconditionally creates a new singleton if one does not exist. Differential Revision: https://phabricator.services.mozilla.com/D86030
This commit is contained in:
Родитель
8b026394da
Коммит
e6886b3c16
|
@ -102,6 +102,7 @@ StaticRefPtr<URLPreloader> URLPreloader::sSingleton;
|
|||
URLPreloader::~URLPreloader() {
|
||||
if (sInitialized) {
|
||||
UnregisterWeakMemoryReporter(this);
|
||||
sInitialized = false;
|
||||
}
|
||||
}
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче