Bug 1245513 - Use _exit(0) to exit in B2G debug content processes. r=froydnj

This skips destructors, so hopefully it avoids some odd behaviors.
This commit is contained in:
Andrew McCreight 2016-02-03 10:00:11 -08:00
parent 55737a5491
commit 56f6791f9b

View File

@ -1042,13 +1042,13 @@ ShutdownXPCOM(nsIServiceManager* aServMgr)
NS_LogTerm();
#if defined(MOZ_WIDGET_GONK)
// This exit(0) call is intended to be temporary, to get shutdown leak
// checking working on Linux.
// This _exit(0) call is intended to be temporary, to get shutdown leak
// checking working on non-B2G platforms.
// On debug B2G, the child process crashes very late. Instead, just
// give up so at least we exit cleanly. See bug 1071866.
if (XRE_IsContentProcess()) {
NS_WARNING("Exiting child process early!");
exit(0);
_exit(0);
}
#endif