Bug 1369002 - Stop warning if the mainThread is null in GetCurrentThread. r=froydnj
authorEric Rahm <erahm@mozilla.com>
Tue, 20 Jun 2017 09:51:29 -0700
changeset 420030 95c0feba19eca15b4d7084e5eb0d5f08b4858b88
parent 420029 add7f83758561c8d534b47af5e98379b4f2f19dd
child 420031 2ad1af89c807dfb0cc6c0c8702e56972d586ccba
push id7566
push usermtabara@mozilla.com
push dateWed, 02 Aug 2017 08:25:16 +0000
treeherdermozilla-beta@86913f512c3c [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersfroydnj
bugs1369002
milestone56.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 1369002 - Stop warning if the mainThread is null in GetCurrentThread. r=froydnj
xpcom/threads/nsThreadManager.cpp
--- a/xpcom/threads/nsThreadManager.cpp
+++ b/xpcom/threads/nsThreadManager.cpp
@@ -325,17 +325,17 @@ nsThreadManager::GetMainThread(nsIThread
   NS_ADDREF(*aResult = mMainThread);
   return NS_OK;
 }
 
 NS_IMETHODIMP
 nsThreadManager::GetCurrentThread(nsIThread** aResult)
 {
   // Keep this functioning during Shutdown
-  if (NS_WARN_IF(!mMainThread)) {
+  if (!mMainThread) {
     return NS_ERROR_NOT_INITIALIZED;
   }
   *aResult = GetCurrentThread();
   if (!*aResult) {
     return NS_ERROR_OUT_OF_MEMORY;
   }
   NS_ADDREF(*aResult);
   return NS_OK;