Bug 1776832 - Clear chrome module environments in shutdown r=arai
Differential Revision: https://phabricator.services.mozilla.com/D150966
This commit is contained in:
@@ -891,6 +891,11 @@ ModuleLoaderBase::~ModuleLoaderBase() {
|
||||
|
||||
void ModuleLoaderBase::Shutdown() {
|
||||
MOZ_ASSERT(mFetchingModules.IsEmpty());
|
||||
|
||||
for (const auto& entry : mFetchedModules) {
|
||||
entry.GetData()->Shutdown();
|
||||
}
|
||||
|
||||
mFetchedModules.Clear();
|
||||
mGlobalObject = nullptr;
|
||||
mEventTarget = nullptr;
|
||||
|
||||
Reference in New Issue
Block a user