File mozilla-aarch64-startup-crash.patch of Package MozillaFirefox.11622

# HG changeset patch
# User msirringhaus@suse.de
# Date 1558421110 -7200
#      Tue May 21 08:45:10 2019 +0200
# Node ID f4a90f7554cc1621a982384d4cb6126461ebb789
# Parent  ed524c311cbc9faae1c92723483f551e57735a81
bsc#991344 - Rpi3: Firefox crashes after a few seconds of usage
bmo#1302554 - ARM/AARCH64: Firefox crashes on NULL nsIChannel** result pointer in nsIOService::NewChannelFromURIWithProxyFlagsInternal()

diff -r ed524c311cbc -r f4a90f7554cc netwerk/base/nsIOService.cpp
--- a/netwerk/base/nsIOService.cpp	Fri Feb 26 16:20:09 2016 +0000
+++ b/netwerk/base/nsIOService.cpp	Tue May 21 08:45:10 2019 +0200
@@ -880,8 +880,14 @@
     }
   }
 
-  channel.forget(result);
-  return NS_OK;
+#if defined(__aarch64__)
+    if (result) {
+        channel.forget(result);
+    }
+#else
+     channel.forget(result);
+#endif
+     return NS_OK;
 }
 
 NS_IMETHODIMP
openSUSE Build Service is sponsored by