Bug 1437188 - Part 1: Remove verbose fetch related warnings. r=bkelly

This removes the most verbose fetch related warnings. Cumulatively these
account for about 11,000 warnings during testing.

--HG--
extra : rebase_source : ee930dec1e18b9a7f34d5c66944dc015be10be69
This commit is contained in:
Eric Rahm 2018-02-09 14:04:03 -08:00
parent d21c84fed8
commit 9f798eecf1
3 changed files with 6 additions and 4 deletions

View File

@ -473,7 +473,7 @@ FetchRequest(nsIGlobalObject* aGlobal, const RequestOrUSVString& aInput,
GlobalObject global(cx, jsGlobal);
RefPtr<Request> request = Request::Constructor(global, aInput, aInit, aRv);
if (NS_WARN_IF(aRv.Failed())) {
if (aRv.Failed()) {
return nullptr;
}

View File

@ -718,7 +718,9 @@ FetchDriver::HttpFetch(const nsACString& aPreferredAlternativeDataType)
} else {
rv = chan->AsyncOpen2(this);
}
NS_ENSURE_SUCCESS(rv, rv);
if (NS_FAILED(rv)) {
return rv;
}
// Step 4 onwards of "HTTP Fetch" is handled internally by Necko.

View File

@ -142,7 +142,7 @@ ParseURLFromChrome(const nsAString& aInput, ErrorResult& aRv)
MOZ_ASSERT(NS_IsMainThread());
nsCOMPtr<nsIURI> uri;
aRv = NS_NewURI(getter_AddRefs(uri), aInput, nullptr, nullptr);
if (NS_WARN_IF(aRv.Failed())) {
if (aRv.Failed()) {
aRv.ThrowTypeError<MSG_INVALID_URL>(aInput);
}
return uri.forget();
@ -328,7 +328,7 @@ Request::Constructor(const GlobalObject& aGlobal,
} else {
GetRequestURLFromWorker(aGlobal, input, requestURL, fragment, aRv);
}
if (NS_WARN_IF(aRv.Failed())) {
if (aRv.Failed()) {
return nullptr;
}
request = new InternalRequest(NS_ConvertUTF16toUTF8(requestURL), fragment);