Bug 1630208 part 1: Assert that we don't add a shut down DocAccessibleParent to the remote XPC cache in DocManager::GetXPCDocument. r=yzen

We really want to know about this because the document will never be removed from the cache, since NotifyOfRemoteDocShutdown (which would normally remove it from the XPC cache) won't get called.

Differential Revision: https://phabricator.services.mozilla.com/D79779
This commit is contained in:
James Teh 2020-06-17 18:37:58 +00:00
Родитель f93d2c823e
Коммит dffc53d36b
1 изменённых файлов: 1 добавлений и 0 удалений

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

@ -145,6 +145,7 @@ xpcAccessibleDocument* DocManager::GetXPCDocument(DocAccessibleParent* aDoc) {
xpcAccessibleDocument>;
}
MOZ_ASSERT(!aDoc->IsShutdown(), "Adding a shutdown doc to remote XPC cache");
doc = new xpcAccessibleDocument(aDoc,
Interfaces::DOCUMENT | Interfaces::HYPERTEXT);
sRemoteXPCDocumentCache->Put(aDoc, RefPtr{doc});