Back out previous logging patches (92791a422f0a and 5617c22ea9ac) for bug 469514.
authorL. David Baron <dbaron@dbaron.org>
Wed, 22 Apr 2009 15:21:17 -0700
changeset 27647 df5794cb4d9a08be3bf253dcdc21f5ad8673188c
parent 27646 d50609a6b63e0c5977f9c034bbebfe03015607eb
child 27648 c762f337c3c4c4b6f50e391f0500cd1586b4fbaa
push id6668
push userdbaron@mozilla.com
push dateWed, 22 Apr 2009 22:21:45 +0000
treeherdermozilla-central@df5794cb4d9a [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
bugs469514
milestone1.9.2a1pre
Back out previous logging patches (92791a422f0a and 5617c22ea9ac) for bug 469514.
xpcom/io/nsStreamUtils.cpp
xpcom/threads/nsThreadManager.cpp
--- a/xpcom/io/nsStreamUtils.cpp
+++ b/xpcom/io/nsStreamUtils.cpp
@@ -93,21 +93,16 @@ public:
     NS_IMETHOD OnInputStreamReady(nsIAsyncInputStream *stream)
     {
         mStream = stream;
 
         nsresult rv =
             mTarget->Dispatch(this, NS_DISPATCH_NORMAL);
         if (NS_FAILED(rv)) {
             NS_WARNING("Dispatch failed");
-#ifdef DEBUG
-            (void)fprintf(stdout,
-                          "### mTarget (%p) may not be accepting events!\n",
-                          mTarget.get());
-#endif
             return NS_ERROR_FAILURE;
         }
 
         return NS_OK;
     }
 
     NS_IMETHOD Run()
     {
@@ -177,21 +172,16 @@ public:
     NS_IMETHOD OnOutputStreamReady(nsIAsyncOutputStream *stream)
     {
         mStream = stream;
 
         nsresult rv =
             mTarget->Dispatch(this, NS_DISPATCH_NORMAL);
         if (NS_FAILED(rv)) {
             NS_WARNING("PostEvent failed");
-#ifdef DEBUG
-            (void)fprintf(stdout,
-                          "### mTarget (%p) may not be accepting events!\n",
-                          mTarget.get());
-#endif
             return NS_ERROR_FAILURE;
         }
 
         return NS_OK;
     }
 
     NS_IMETHOD Run()
     {
--- a/xpcom/threads/nsThreadManager.cpp
+++ b/xpcom/threads/nsThreadManager.cpp
@@ -38,31 +38,16 @@
 
 #include "nsThreadManager.h"
 #include "nsThread.h"
 #include "nsIClassInfoImpl.h"
 #include "nsTArray.h"
 #include "nsAutoPtr.h"
 #include "nsAutoLock.h"
 
-#ifdef DEBUG
-#include "nsStackWalk.h"
-
-static void
-thread_stack_callback(void *aPC, void *)
-{
-  char buf[1024];
-  nsCodeAddressDetails details;
-
-  (void)NS_DescribeCodeAddress(aPC, &details);
-  (void)NS_FormatCodeAddressDetails(aPC, &details, buf, sizeof(buf));
-  (void)fprintf(stdout, buf);
-}
-#endif
-
 typedef nsTArray< nsRefPtr<nsThread> > nsThreadArray;
 
 //-----------------------------------------------------------------------------
 
 static void
 ReleaseObject(void *data)
 {
   static_cast<nsISupports *>(data)->Release();
@@ -242,21 +227,16 @@ nsThreadManager::NewThread(PRUint32 crea
   if (NS_FAILED(rv)) {
     NS_RELEASE(thr);
     return rv;
   }
 
   // At this point, we expect that the thread has been registered in mThread;
   // however, it is possible that it could have also been replaced by now, so
   // we cannot really assert that it was added.
-#ifdef DEBUG
-  (void)fprintf(stdout, "### Creating thread with address %p\n", thr);
-  (void)NS_StackWalk(thread_stack_callback, 0, nsnull);
-  (void)fprintf(stdout, "\n\n");
-#endif
 
   *result = thr;
   return NS_OK;
 }
 
 NS_IMETHODIMP
 nsThreadManager::GetThreadFromPRThread(PRThread *thread, nsIThread **result)
 {