Bug 1356538 - Carry class-of-service flags to redirected channels. r=mcmanus

--HG--
extra : rebase_source : a0688aa4f470fe377de3cc377f2eb8a2c67bef0c
This commit is contained in:
Honza Bambas 2017-05-31 05:06:00 -04:00
parent 1c495d8974
commit d02e6da08f

View File

@ -3145,6 +3145,11 @@ HttpBaseChannel::SetupReplacementChannel(nsIURI *newURI,
newChannel->SetNotificationCallbacks(mCallbacks);
newChannel->SetLoadFlags(newLoadFlags);
nsCOMPtr<nsIClassOfService> cos(do_QueryInterface(newChannel));
if (cos) {
cos->SetClassFlags(mClassOfService);
}
// Try to preserve the privacy bit if it has been overridden
if (mPrivateBrowsingOverriden) {
nsCOMPtr<nsIPrivateBrowsingChannel> newPBChannel =