Bug 1328847 - Part 2: Change SEC_NORMAL to SEC_ALLOW_CROSS_ORIGIN_DATA_IS_NULL where null principal is used. rs=bustage-fix
This commit is contained in:
Родитель
35396558af
Коммит
6cf908938f
|
@ -125,7 +125,7 @@ nsAbContentHandler::HandleContent(const char *aContentType,
|
|||
uri,
|
||||
this,
|
||||
nullPrincipal,
|
||||
nsILoadInfo::SEC_NORMAL,
|
||||
nsILoadInfo::SEC_ALLOW_CROSS_ORIGIN_DATA_IS_NULL,
|
||||
nsIContentPolicy::TYPE_OTHER);
|
||||
NS_ENSURE_SUCCESS(rv, rv);
|
||||
|
||||
|
|
|
@ -114,8 +114,11 @@ nsAddbookProtocolHandler::GenerateXMLOutputChannel( nsString &aOutput,
|
|||
if (NS_FAILED(rv))
|
||||
return rv;
|
||||
|
||||
return NS_NewInputStreamChannel(_retval, aURI, inStr,
|
||||
nullPrincipal, nsILoadInfo::SEC_NORMAL,
|
||||
return NS_NewInputStreamChannel(_retval,
|
||||
aURI,
|
||||
inStr,
|
||||
nullPrincipal,
|
||||
nsILoadInfo::SEC_ALLOW_CROSS_ORIGIN_DATA_IS_NULL,
|
||||
nsIContentPolicy::TYPE_OTHER,
|
||||
NS_LITERAL_CSTRING("text/xml"));
|
||||
}
|
||||
|
@ -179,10 +182,14 @@ nsAddbookProtocolHandler::NewChannel2(nsIURI *aURI,
|
|||
NS_ASSERTION(NS_SUCCEEDED(rv), "CreateInstance of nullprincipal failed.");
|
||||
if (NS_FAILED(rv))
|
||||
return rv;
|
||||
|
||||
return NS_NewInputStreamChannel(_retval, aURI, pipeIn,
|
||||
nullPrincipal, nsILoadInfo::SEC_NORMAL, nsIContentPolicy::TYPE_OTHER,
|
||||
NS_LITERAL_CSTRING("application/x-addvcard"));
|
||||
|
||||
return NS_NewInputStreamChannel(_retval,
|
||||
aURI,
|
||||
pipeIn,
|
||||
nullPrincipal,
|
||||
nsILoadInfo::SEC_ALLOW_CROSS_ORIGIN_DATA_IS_NULL,
|
||||
nsIContentPolicy::TYPE_OTHER,
|
||||
NS_LITERAL_CSTRING("application/x-addvcard"));
|
||||
}
|
||||
|
||||
nsString output;
|
||||
|
|
|
@ -1108,7 +1108,7 @@ nsMessenger::SaveAs(const nsACString& aURI, bool aAsFile,
|
|||
url,
|
||||
nullptr,
|
||||
nullPrincipal,
|
||||
nsILoadInfo::SEC_NORMAL,
|
||||
nsILoadInfo::SEC_ALLOW_CROSS_ORIGIN_DATA_IS_NULL,
|
||||
nsIContentPolicy::TYPE_OTHER);
|
||||
NS_ASSERTION(NS_SUCCEEDED(rv), "NS_NewChannel failed");
|
||||
if (NS_FAILED(rv))
|
||||
|
|
|
@ -661,7 +661,7 @@ nsMsgAttachmentHandler::SnarfMsgAttachment(nsMsgCompFields *compFields)
|
|||
aURL,
|
||||
nullptr,
|
||||
nullPrincipal,
|
||||
nsILoadInfo::SEC_NORMAL,
|
||||
nsILoadInfo::SEC_ALLOW_CROSS_ORIGIN_DATA_IS_NULL,
|
||||
nsIContentPolicy::TYPE_OTHER);
|
||||
if (NS_FAILED(rv))
|
||||
goto done;
|
||||
|
|
|
@ -1352,11 +1352,11 @@ nsMsgComposeService::RunMessageThroughMimeDraft(
|
|||
|
||||
nsCOMPtr<nsIChannel> channel;
|
||||
rv = NS_NewInputStreamChannel(getter_AddRefs(channel),
|
||||
url,
|
||||
nullptr,
|
||||
nullPrincipal,
|
||||
nsILoadInfo::SEC_NORMAL,
|
||||
nsIContentPolicy::TYPE_OTHER);
|
||||
url,
|
||||
nullptr,
|
||||
nullPrincipal,
|
||||
nsILoadInfo::SEC_ALLOW_CROSS_ORIGIN_DATA_IS_NULL,
|
||||
nsIContentPolicy::TYPE_OTHER);
|
||||
NS_ASSERTION(NS_SUCCEEDED(rv), "NS_NewChannel failed.");
|
||||
if (NS_FAILED(rv))
|
||||
return rv;
|
||||
|
|
|
@ -357,8 +357,11 @@ NS_IMETHODIMP nsSmtpService::NewChannel2(nsIURI *aURI,
|
|||
if (NS_FAILED(rv))
|
||||
return rv;
|
||||
|
||||
return NS_NewInputStreamChannel(_retval, aURI, pipeIn,
|
||||
nullPrincipal, nsILoadInfo::SEC_NORMAL,
|
||||
return NS_NewInputStreamChannel(_retval,
|
||||
aURI,
|
||||
pipeIn,
|
||||
nullPrincipal,
|
||||
nsILoadInfo::SEC_ALLOW_CROSS_ORIGIN_DATA_IS_NULL,
|
||||
nsIContentPolicy::TYPE_OTHER,
|
||||
NS_LITERAL_CSTRING("application/x-mailto"));
|
||||
}
|
||||
|
|
|
@ -325,7 +325,7 @@ nsURLFetcher::FireURLRequest(nsIURI *aURL, nsIFile *localFile, nsIOutputStream *
|
|||
rv = NS_NewChannel(getter_AddRefs(channel),
|
||||
aURL,
|
||||
nullPrincipal,
|
||||
nsILoadInfo::SEC_NORMAL,
|
||||
nsILoadInfo::SEC_ALLOW_CROSS_ORIGIN_DATA_IS_NULL,
|
||||
nsIContentPolicy::TYPE_OTHER,
|
||||
nullptr, // aLoadGroup
|
||||
this); // aCallbacks
|
||||
|
|
|
@ -728,7 +728,7 @@ nsresult nsImapProtocol::SetupWithUrl(nsIURI * aURL, nsISupports* aConsumer)
|
|||
rv = NS_NewChannel(getter_AddRefs(channel),
|
||||
aURL,
|
||||
nullPrincipal,
|
||||
nsILoadInfo::SEC_NORMAL,
|
||||
nsILoadInfo::SEC_ALLOW_CROSS_ORIGIN_DATA_IS_NULL,
|
||||
nsIContentPolicy::TYPE_OTHER);
|
||||
m_mockChannel = do_QueryInterface(channel);
|
||||
|
||||
|
|
Загрузка…
Ссылка в новой задаче