mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-10-21 09:15:35 +00:00
Bug 1638172 - avoid name hiding for handling multipart channel in HttpChannelChild, r=mayhemer
Differential Revision: https://phabricator.services.mozilla.com/D75445
This commit is contained in:
parent
f2056ea3ec
commit
b966699767
@ -1485,10 +1485,13 @@ HttpChannelParent::OnStartRequest(nsIRequest* aRequest) {
|
||||
cleanedUpResponseHead = *responseHead;
|
||||
cleanedUpResponseHead.ClearHeader(nsHttp::Set_Cookie);
|
||||
if (multiPartID) {
|
||||
nsCOMPtr<nsIChannel> chan = do_QueryInterface(aRequest);
|
||||
MOZ_ASSERT(chan);
|
||||
nsCOMPtr<nsIChannel> multiPartChannel = do_QueryInterface(aRequest);
|
||||
// For the multipart channel, use the parsed subtype instead. Note that
|
||||
// `chan` is the underlying base channel of the multipart channel in this
|
||||
// case, which is different from `multiPartChannel`.
|
||||
MOZ_ASSERT(multiPartChannel);
|
||||
nsAutoCString contentType;
|
||||
chan->GetContentType(contentType);
|
||||
multiPartChannel->GetContentType(contentType);
|
||||
cleanedUpResponseHead.SetContentType(contentType);
|
||||
}
|
||||
responseHead = &cleanedUpResponseHead;
|
||||
|
Loading…
Reference in New Issue
Block a user