Bug 1596665 - P5. Pass last site information from the parent and remove DCC's nsHashPropertyBag inheritance. r=mayhemer,kmag

The previous site URI is now only written on the parent and sent back to the child once all redirects have completed.

In a follow up we will also transfer this information when a process switch occur as it's currently broken.

Differential Revision: https://phabricator.services.mozilla.com/D53926
This commit is contained in:
Jean-Yves Avenard
2019-11-26 01:47:48 +00:00
parent 586eaab253
commit 8a48fe9a76
5 changed files with 75 additions and 35 deletions

View File

@@ -6119,7 +6119,7 @@ void nsDocShell::OnRedirectStateChange(nsIChannel* aOldChannel,
if (RefPtr<DocumentChannelChild> docChannel = do_QueryObject(aOldChannel)) {
nsCOMPtr<nsIURI> previousURI;
uint32_t previousFlags = 0;
ExtractLastVisit(aOldChannel, getter_AddRefs(previousURI), &previousFlags);
docChannel->GetLastVisit(getter_AddRefs(previousURI), &previousFlags);
for (auto redirect : docChannel->GetRedirectChain()) {
if (!redirect.isPost()) {