Backed out changeset e8a63038d787 (bug 1372426) for build failures in nsStringStream.cpp a=backout
authorWes Kocher <wkocher@mozilla.com>
Tue, 13 Jun 2017 15:20:12 -0700
changeset 363847 df7898194f590a0bcc8cfe02766617101e3aa26b
parent 363846 4a93ea01749a241f048f06bd02ad9c4c1183f0d7
child 363848 45b5cadadc22bd1c0991cc14fdf6e3c4c6ccf73b
push id32027
push usercbook@mozilla.com
push dateWed, 14 Jun 2017 12:45:45 +0000
treeherdermozilla-central@45fde181a497 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersbackout
bugs1372426
milestone56.0a1
backs oute8a63038d7870bf67211a5db7c933727ef4600f5
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
Backed out changeset e8a63038d787 (bug 1372426) for build failures in nsStringStream.cpp a=backout MozReview-Commit-ID: 8ci8nKoiLhz
image/encoders/bmp/nsBMPEncoder.cpp
image/encoders/ico/nsICOEncoder.cpp
image/encoders/jpeg/nsJPEGEncoder.cpp
image/encoders/png/nsPNGEncoder.cpp
netwerk/base/ThrottleQueue.cpp
netwerk/base/nsBaseContentStream.cpp
netwerk/base/nsSocketTransport2.cpp
netwerk/cache2/CacheFileInputStream.cpp
netwerk/protocol/device/AndroidCaptureProvider.cpp
xpcom/io/nsPipe3.cpp
xpcom/io/nsStreamUtils.cpp
xpcom/io/nsStreamUtils.h
--- a/image/encoders/bmp/nsBMPEncoder.cpp
+++ b/image/encoders/bmp/nsBMPEncoder.cpp
@@ -478,18 +478,17 @@ nsBMPEncoder::ConvertHostARGBRow(const u
 void
 nsBMPEncoder::NotifyListener()
 {
   if (mCallback &&
       (GetCurrentImageBufferOffset() - mImageBufferReadPoint >=
        mNotifyThreshold || mFinished)) {
     nsCOMPtr<nsIInputStreamCallback> callback;
     if (mCallbackTarget) {
-      callback = NS_NewInputStreamReadyEvent("nsBMPEncoder::NotifyListener",
-                                             mCallback, mCallbackTarget);
+      callback = NS_NewInputStreamReadyEvent(mCallback, mCallbackTarget);
     } else {
       callback = mCallback;
     }
 
     NS_ASSERTION(callback, "Shouldn't fail to make the callback");
     // Null the callback first because OnInputStreamReady could
     // reenter AsyncWait
     mCallback = nullptr;
--- a/image/encoders/ico/nsICOEncoder.cpp
+++ b/image/encoders/ico/nsICOEncoder.cpp
@@ -437,18 +437,17 @@ nsICOEncoder::CloseWithStatus(nsresult a
 void
 nsICOEncoder::NotifyListener()
 {
   if (mCallback &&
       (GetCurrentImageBufferOffset() -
          mImageBufferReadPoint >= mNotifyThreshold || mFinished)) {
     nsCOMPtr<nsIInputStreamCallback> callback;
     if (mCallbackTarget) {
-      callback = NS_NewInputStreamReadyEvent("nsICOEncoder::NotifyListener",
-                                             mCallback, mCallbackTarget);
+      callback = NS_NewInputStreamReadyEvent(mCallback, mCallbackTarget);
     } else {
       callback = mCallback;
     }
 
     NS_ASSERTION(callback, "Shouldn't fail to make the callback");
     // Null the callback first because OnInputStreamReady could reenter
     // AsyncWait
     mCallback = nullptr;
--- a/image/encoders/jpeg/nsJPEGEncoder.cpp
+++ b/image/encoders/jpeg/nsJPEGEncoder.cpp
@@ -510,18 +510,17 @@ nsJPEGEncoder::NotifyListener()
   // image).
   ReentrantMonitorAutoEnter autoEnter(mReentrantMonitor);
 
   if (mCallback &&
       (mImageBufferUsed - mImageBufferReadPoint >= mNotifyThreshold ||
        mFinished)) {
     nsCOMPtr<nsIInputStreamCallback> callback;
     if (mCallbackTarget) {
-      callback = NS_NewInputStreamReadyEvent("nsJPEGEncoder::NotifyListener",
-                                             mCallback, mCallbackTarget);
+      callback = NS_NewInputStreamReadyEvent(mCallback, mCallbackTarget);
     } else {
       callback = mCallback;
     }
 
     NS_ASSERTION(callback, "Shouldn't fail to make the callback");
     // Null the callback first because OnInputStreamReady could reenter
     // AsyncWait
     mCallback = nullptr;
--- a/image/encoders/png/nsPNGEncoder.cpp
+++ b/image/encoders/png/nsPNGEncoder.cpp
@@ -736,18 +736,17 @@ nsPNGEncoder::NotifyListener()
   // image).
   ReentrantMonitorAutoEnter autoEnter(mReentrantMonitor);
 
   if (mCallback &&
       (mImageBufferUsed - mImageBufferReadPoint >= mNotifyThreshold ||
        mFinished)) {
     nsCOMPtr<nsIInputStreamCallback> callback;
     if (mCallbackTarget) {
-      callback = NS_NewInputStreamReadyEvent("nsPNGEncoder::NotifyListener",
-                                             mCallback, mCallbackTarget);
+      callback = NS_NewInputStreamReadyEvent(mCallback, mCallbackTarget);
     } else {
       callback = mCallback;
     }
 
     NS_ASSERTION(callback, "Shouldn't fail to make the callback");
     // Null the callback first because OnInputStreamReady could reenter
     // AsyncWait
     mCallback = nullptr;
--- a/netwerk/base/ThrottleQueue.cpp
+++ b/netwerk/base/ThrottleQueue.cpp
@@ -221,18 +221,17 @@ ThrottleInputStream::AsyncWait(nsIInputS
   return NS_OK;
 }
 
 void
 ThrottleInputStream::AllowInput()
 {
   MOZ_ASSERT(mCallback);
   nsCOMPtr<nsIInputStreamCallback> callbackEvent =
-    NS_NewInputStreamReadyEvent("ThrottleInputStream::AllowInput",
-                                mCallback, mEventTarget);
+    NS_NewInputStreamReadyEvent(mCallback, mEventTarget);
   mCallback = nullptr;
   mEventTarget = nullptr;
   callbackEvent->OnInputStreamReady(this);
 }
 
 //-----------------------------------------------------------------------------
 
 NS_IMPL_ISUPPORTS(ThrottleQueue, nsIInputChannelThrottleQueue, nsITimerCallback)
--- a/netwerk/base/nsBaseContentStream.cpp
+++ b/netwerk/base/nsBaseContentStream.cpp
@@ -14,18 +14,17 @@ nsBaseContentStream::DispatchCallback(bo
   if (!mCallback)
     return;
 
   // It's important to clear mCallback and mCallbackTarget up-front because the
   // OnInputStreamReady implementation may call our AsyncWait method.
 
   nsCOMPtr<nsIInputStreamCallback> callback;
   if (async) {
-      callback = NS_NewInputStreamReadyEvent("nsBaseContentStream::DispatchCallback",
-                                             mCallback, mCallbackTarget);
+    callback = NS_NewInputStreamReadyEvent(mCallback, mCallbackTarget);
     mCallback = nullptr;
   } else {
     callback.swap(mCallback);
   }
   mCallbackTarget = nullptr;
 
   callback->OnInputStreamReady(this);
 }
--- a/netwerk/base/nsSocketTransport2.cpp
+++ b/netwerk/base/nsSocketTransport2.cpp
@@ -481,18 +481,17 @@ nsSocketInputStream::AsyncWait(nsIInputS
     bool hasError = false;
     {
         MutexAutoLock lock(mTransport->mLock);
 
         if (callback && target) {
             //
             // build event proxy
             //
-            mCallback = NS_NewInputStreamReadyEvent("nsSocketInputStream::AsyncWait",
-                                                    callback, target);
+            mCallback = NS_NewInputStreamReadyEvent(callback, target);
         }
         else
             mCallback = callback;
         mCallbackFlags = flags;
 
         hasError = NS_FAILED(mCondition);
     } // unlock mTransport->mLock
 
--- a/netwerk/cache2/CacheFileInputStream.cpp
+++ b/netwerk/cache2/CacheFileInputStream.cpp
@@ -630,18 +630,17 @@ CacheFileInputStream::NotifyListener()
     if (!mCallbackTarget) {
       LOG(("CacheFileInputStream::NotifyListener() - Cannot get Cache I/O "
            "thread! Using main thread for callback."));
       mCallbackTarget = GetMainThreadEventTarget();
     }
   }
 
   nsCOMPtr<nsIInputStreamCallback> asyncCallback =
-    NS_NewInputStreamReadyEvent("CacheFileInputStream::NotifyListener",
-                                mCallback, mCallbackTarget);
+    NS_NewInputStreamReadyEvent(mCallback, mCallbackTarget);
 
   mCallback = nullptr;
   mCallbackTarget = nullptr;
 
   asyncCallback->OnInputStreamReady(this);
 }
 
 void
--- a/netwerk/protocol/device/AndroidCaptureProvider.cpp
+++ b/netwerk/protocol/device/AndroidCaptureProvider.cpp
@@ -207,18 +207,17 @@ void AndroidCameraInputStream::doClose()
 
 
 void AndroidCameraInputStream::NotifyListeners() {
   mozilla::ReentrantMonitorAutoEnter autoMonitor(mMonitor);
   
   if (mCallback && (mAvailable > sizeof(RawVideoHeader))) {
     nsCOMPtr<nsIInputStreamCallback> callback;
     if (mCallbackTarget) {
-      callback = NS_NewInputStreamReadyEvent("AndroidCameraInputStream::NotifyListeners",
-                                             mCallback, mCallbackTarget);
+      callback = NS_NewInputStreamReadyEvent(mCallback, mCallbackTarget);
     } else {
       callback = mCallback;
     }
 
     NS_ASSERTION(callback, "Shouldn't fail to make the callback!");
 
     // Null the callback first because OnInputStreamReady may reenter AsyncWait
     mCallback = nullptr;
--- a/xpcom/io/nsPipe3.cpp
+++ b/xpcom/io/nsPipe3.cpp
@@ -1488,18 +1488,17 @@ nsPipeInputStream::AsyncWait(nsIInputStr
     mCallbackFlags = 0;
 
     if (!aCallback) {
       return NS_OK;
     }
 
     nsCOMPtr<nsIInputStreamCallback> proxy;
     if (aTarget) {
-      proxy = NS_NewInputStreamReadyEvent("nsPipeInputStream::AsyncWait",
-                                          aCallback, aTarget);
+      proxy = NS_NewInputStreamReadyEvent(aCallback, aTarget);
       aCallback = proxy;
     }
 
     if (NS_FAILED(Status(mon)) ||
        (mReadState.mAvailable && !(aFlags & WAIT_CLOSURE_ONLY))) {
       // stream is already closed or readable; post event.
       pipeEvents.NotifyInputReady(this, aCallback);
     } else {
--- a/xpcom/io/nsStreamUtils.cpp
+++ b/xpcom/io/nsStreamUtils.cpp
@@ -31,20 +31,19 @@ using namespace mozilla;
 // instead of Run().
 class nsInputStreamReadyEvent final
   : public CancelableRunnable
   , public nsIInputStreamCallback
 {
 public:
   NS_DECL_ISUPPORTS_INHERITED
 
-    nsInputStreamReadyEvent(const char* aName,
-                            nsIInputStreamCallback* aCallback,
-                            nsIEventTarget* aTarget)
-    : CancelableRunnable(aName)
+  nsInputStreamReadyEvent(nsIInputStreamCallback* aCallback,
+                          nsIEventTarget* aTarget)
+    : CancelableRunnable("nsInputStreamReadyEvent")
     , mCallback(aCallback)
     , mTarget(aTarget)
   {
   }
 
 private:
   ~nsInputStreamReadyEvent()
   {
@@ -57,17 +56,17 @@ private:
     // calling thread, then we are ok.  otherwise, we have to try to
     // proxy the Release over the right thread.  if that thread is dead,
     // then there's nothing we can do... better to leak than crash.
     //
     bool val;
     nsresult rv = mTarget->IsOnCurrentThread(&val);
     if (NS_FAILED(rv) || !val) {
       nsCOMPtr<nsIInputStreamCallback> event =
-        NS_NewInputStreamReadyEvent("~nsInputStreamReadyEvent", mCallback, mTarget);
+        NS_NewInputStreamReadyEvent(mCallback, mTarget);
       mCallback = nullptr;
       if (event) {
         rv = event->OnInputStreamReady(nullptr);
         if (NS_FAILED(rv)) {
           NS_NOTREACHED("leaking stream event");
           nsISupports* sup = event;
           NS_ADDREF(sup);
         }
@@ -205,24 +204,23 @@ private:
 };
 
 NS_IMPL_ISUPPORTS_INHERITED(nsOutputStreamReadyEvent, CancelableRunnable,
                             nsIOutputStreamCallback)
 
 //-----------------------------------------------------------------------------
 
 already_AddRefed<nsIInputStreamCallback>
-NS_NewInputStreamReadyEvent(const char* aName,
-                            nsIInputStreamCallback* aCallback,
+NS_NewInputStreamReadyEvent(nsIInputStreamCallback* aCallback,
                             nsIEventTarget* aTarget)
 {
   NS_ASSERTION(aCallback, "null callback");
   NS_ASSERTION(aTarget, "null target");
   RefPtr<nsInputStreamReadyEvent> ev =
-    new nsInputStreamReadyEvent(aName, aCallback, aTarget);
+    new nsInputStreamReadyEvent(aCallback, aTarget);
   return ev.forget();
 }
 
 already_AddRefed<nsIOutputStreamCallback>
 NS_NewOutputStreamReadyEvent(nsIOutputStreamCallback* aCallback,
                              nsIEventTarget* aTarget)
 {
   NS_ASSERTION(aCallback, "null callback");
--- a/xpcom/io/nsStreamUtils.h
+++ b/xpcom/io/nsStreamUtils.h
@@ -23,18 +23,17 @@ class nsIEventTarget;
  * proxy object ensures that the real notify object will be free'd on the
  * thread corresponding to the given event target regardless of what thread
  * the proxy object is destroyed on.
  *
  * This function is designed to be used to implement AsyncWait when the
  * aTarget parameter is non-null.
  */
 extern already_AddRefed<nsIInputStreamCallback>
-NS_NewInputStreamReadyEvent(const char* aName,
-                            nsIInputStreamCallback* aNotify,
+NS_NewInputStreamReadyEvent(nsIInputStreamCallback* aNotify,
                             nsIEventTarget* aTarget);
 
 /**
  * A "one-shot" proxy of the OnOutputStreamReady callback.  The resulting
  * proxy object's OnOutputStreamReady function may only be called once!  The
  * proxy object ensures that the real notify object will be free'd on the
  * thread corresponding to the given event target regardless of what thread
  * the proxy object is destroyed on.