Bug 1703692 - Store the latest embedder's permanent key on CanonicalBrowsingContext, r=nika,mccr8

And include it in Session Store flushes to avoid dropping updates in case the
browser is unavailable.

Differential Revision: https://phabricator.services.mozilla.com/D118385
This commit is contained in:
Kashav Madan
2021-06-24 20:26:13 +00:00
parent d63be831bf
commit bc90a488f7
10 changed files with 190 additions and 75 deletions

View File

@@ -693,6 +693,10 @@ void BrowsingContext::SetEmbedderElement(Element* aEmbedder) {
MOZ_ALWAYS_SUCCEEDS(txn.Commit(this));
}
if (XRE_IsParentProcess() && IsTopContent()) {
Canonical()->MaybeSetPermanentKey(aEmbedder);
}
mEmbedderElement = aEmbedder;
if (mEmbedderElement) {