Bug 1110928, part 1 - Hoist the LOAD_END PokeGC out of nsJSContext::LoadEnd. r=smaug

nsDocumentViewer knows which document is involved which will help us later.

Also, fix a typo in the comment.
This commit is contained in:
Andrew McCreight 2015-01-04 17:46:50 -08:00
Родитель 7a91a82059
Коммит 9316f22371
2 изменённых файлов: 3 добавлений и 2 удалений

Просмотреть файл

@ -2089,9 +2089,7 @@ nsJSContext::LoadEnd()
return;
}
// Its probably a good idea to GC soon since we have finished loading.
sLoadingInProgress = false;
PokeGC(JS::gcreason::LOAD_END);
}
// Only trigger expensive timers when they have been checked a number of times.

Просмотреть файл

@ -1039,6 +1039,9 @@ nsDocumentViewer::LoadComplete(nsresult aStatus)
nsJSContext::LoadEnd();
// It's probably a good idea to GC soon since we have finished loading.
nsJSContext::PokeGC(JS::gcreason::LOAD_END);
#ifdef NS_PRINTING
// Check to see if someone tried to print during the load
if (mPrintIsPending) {