bug 1540283 - 62,700 instances of "NS_ENSURE_SUCCESS(rv, rv) failed with result 0x80004005" emitted from netwerk/base/nsIOService.cpp during linux64 debug testing r=valentin
authorKhyati Agarwal <f20160385@hyderabad.bits-pilani.ac.in>
Mon, 01 Apr 2019 05:41:49 +0000
changeset 467925 130653bcfef08ffa4a0a122c87f7b675c20ad665
parent 467923 3f56360e90add2384b4137b8a092b8c544f8b126
child 467926 6dc5bafd664927f4d7ddc2d67964108d81f03eb9
push id112667
push useraiakab@mozilla.com
push dateThu, 04 Apr 2019 16:12:45 +0000
treeherdermozilla-inbound@230bb363f2f3 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersvalentin
bugs1540283
milestone68.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
bug 1540283 - 62,700 instances of "NS_ENSURE_SUCCESS(rv, rv) failed with result 0x80004005" emitted from netwerk/base/nsIOService.cpp during linux64 debug testing r=valentin Replaced "NS_ENSURE_SUCCESS" with 'if' condition Differential Revision: https://phabricator.services.mozilla.com/D25523
netwerk/base/nsIOService.cpp
--- a/netwerk/base/nsIOService.cpp
+++ b/netwerk/base/nsIOService.cpp
@@ -950,17 +950,17 @@ nsresult nsIOService::NewChannelFromURIW
   nsCOMPtr<nsIChannel> channel;
   nsCOMPtr<nsIProxiedProtocolHandler> pph = do_QueryInterface(handler);
   if (pph) {
     rv = pph->NewProxiedChannel(aURI, nullptr, aProxyFlags, aProxyURI,
                                 aLoadInfo, getter_AddRefs(channel));
   } else {
     rv = handler->NewChannel(aURI, aLoadInfo, getter_AddRefs(channel));
   }
-  NS_ENSURE_SUCCESS(rv, rv);
+  if (NS_FAILED(rv)) return rv;
 
   // Make sure that all the individual protocolhandlers attach a loadInfo.
   if (aLoadInfo) {
     // make sure we have the same instance of loadInfo on the newly created
     // channel
     nsCOMPtr<nsILoadInfo> loadInfo = channel->LoadInfo();
     if (aLoadInfo != loadInfo) {
       MOZ_ASSERT(false, "newly created channel must have a loadinfo attached");