Bug 1306327 - Avoid call to NS_DebugBreak from content_process_main(). r=billm
authorMike Hommey <mh+mozilla@glandium.org>
Tue, 10 Jan 2017 17:50:04 +0900
changeset 357842 be999ce0e4fe0354bd2737504cca7fccf206f94e
parent 357841 8e583d30ce9816b92a180ce34b0559c7e09e04a3
child 357843 a7dac14f91df3f94ed809465f80833c310a99f0c
push id10621
push userjlund@mozilla.com
push dateMon, 23 Jan 2017 16:02:43 +0000
treeherdermozilla-aurora@dca7b42e6c67 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbillm
bugs1306327
milestone53.0a1
Bug 1306327 - Avoid call to NS_DebugBreak from content_process_main(). r=billm We want to avoid calls to XPCOM glue functions, in order to remove them later on.
ipc/contentproc/plugin-container.cpp
--- a/ipc/contentproc/plugin-container.cpp
+++ b/ipc/contentproc/plugin-container.cpp
@@ -107,12 +107,10 @@ content_process_main(int argc, char* arg
 #if !defined(XP_LINUX) && defined(MOZ_PLUGIN_CONTAINER)
     // On Windows and MacOS, the GMPLoader lives in plugin-container, so that its
     // code can be covered by an EME/GMP vendor's voucher.
     if (XRE_GetProcessType() == GeckoProcessType_GMPlugin) {
         childData.gmpLoader = mozilla::gmp::CreateGMPLoader(MakeSandboxStarter());
     }
 #endif
     nsresult rv = XRE_InitChildProcess(argc, argv, &childData);
-    NS_ENSURE_SUCCESS(rv, 1);
-
-    return 0;
+    return NS_FAILED(rv);
 }