Bug 1216793 - check against tracking protection list in fetch(). r=gcp

This commit is contained in:
Francois Marier 2015-11-30 16:27:56 -08:00
parent d9abd9a142
commit dafc070491

View File

@ -245,6 +245,8 @@ FetchDriver::HttpFetch()
MOZ_ASSERT(mLoadGroup);
nsCOMPtr<nsIChannel> chan;
nsLoadFlags loadFlags = nsIRequest::LOAD_NORMAL | credentialsFlag |
bypassFlag | nsIChannel::LOAD_CLASSIFY_URI;
if (mDocument) {
MOZ_ASSERT(mDocument->NodePrincipal() == mPrincipal);
rv = NS_NewChannel(getter_AddRefs(chan),
@ -255,7 +257,7 @@ FetchDriver::HttpFetch()
mRequest->ContentPolicyType(),
mLoadGroup,
nullptr, /* aCallbacks */
nsIRequest::LOAD_NORMAL | credentialsFlag | bypassFlag,
loadFlags,
ios);
} else {
rv = NS_NewChannel(getter_AddRefs(chan),
@ -266,7 +268,7 @@ FetchDriver::HttpFetch()
mRequest->ContentPolicyType(),
mLoadGroup,
nullptr, /* aCallbacks */
nsIRequest::LOAD_NORMAL | credentialsFlag | bypassFlag,
loadFlags,
ios);
}
NS_ENSURE_SUCCESS(rv, rv);