Bug 1210941 P12 Remove http channel's ForceNoIntercept. r=jduell IGNORE IDL

This commit is contained in:
Ben Kelly 2015-10-06 06:37:07 -07:00
parent f5df233048
commit ae148e37ee
6 changed files with 11 additions and 20 deletions

View File

@ -2114,13 +2114,6 @@ HttpBaseChannel::GetLastModifiedTime(PRTime* lastModifiedTime)
return NS_OK;
}
NS_IMETHODIMP
HttpBaseChannel::ForceNoIntercept()
{
mLoadFlags |= LOAD_BYPASS_SERVICE_WORKER;
return NS_OK;
}
NS_IMETHODIMP
HttpBaseChannel::GetCorsIncludeCredentials(bool* aInclude)
{

View File

@ -196,7 +196,6 @@ public:
NS_IMETHOD SetNetworkInterfaceId(const nsACString& aNetworkInterfaceId) override;
NS_IMETHOD ForcePending(bool aForcePending) override;
NS_IMETHOD GetLastModifiedTime(PRTime* lastModifiedTime) override;
NS_IMETHOD ForceNoIntercept() override;
NS_IMETHOD GetCorsIncludeCredentials(bool* aInclude) override;
NS_IMETHOD SetCorsIncludeCredentials(bool aInclude) override;
NS_IMETHOD GetCorsMode(uint32_t* aCorsMode) override;

View File

@ -2243,7 +2243,7 @@ HttpChannelChild::ResetInterception()
// The chance to intercept any further requests associated with this channel
// (such as redirects) has passed.
ForceNoIntercept();
mLoadFlags |= LOAD_BYPASS_SERVICE_WORKER;
// Continue with the original cross-process request
nsresult rv = ContinueAsyncOpen();

View File

@ -503,7 +503,10 @@ HttpChannelParent::DoAsyncOpen( const URIParams& aURI,
}
} else {
mChannel->ForceNoIntercept();
nsLoadFlags loadFlags;
mChannel->GetLoadFlags(&loadFlags);
loadFlags |= nsIChannel::LOAD_BYPASS_SERVICE_WORKER;
mChannel->SetLoadFlags(loadFlags);
}
nsCOMPtr<nsISupportsPRUint32> cacheKey =

View File

@ -2009,10 +2009,12 @@ nsHttpChannel::StartRedirectChannelToURI(nsIURI *upgradedURI, uint32_t flags)
// Ensure that internally-redirected channels cannot be intercepted, which would look
// like two separate requests to the nsINetworkInterceptController.
nsCOMPtr<nsIHttpChannelInternal> httpRedirect = do_QueryInterface(mRedirectChannel);
if (httpRedirect) {
httpRedirect->ForceNoIntercept();
}
nsLoadFlags loadFlags = nsIRequest::LOAD_NORMAL;
rv = mRedirectChannel->GetLoadFlags(&loadFlags);
NS_ENSURE_SUCCESS(rv, rv);
loadFlags |= nsIChannel::LOAD_BYPASS_SERVICE_WORKER;
rv = mRedirectChannel->SetLoadFlags(loadFlags);
NS_ENSURE_SUCCESS(rv, rv);
PushRedirectAsyncFunc(
&nsHttpChannel::ContinueAsyncRedirectChannelToURI);

View File

@ -223,12 +223,6 @@ interface nsIHttpChannelInternal : nsISupports
readonly attribute PRTime lastModifiedTime;
/**
* Force a channel that has not been AsyncOpen'ed to skip any check for possible
* interception and proceed immediately to the network/cache.
*/
void forceNoIntercept();
readonly attribute boolean responseSynthesized;
/**