diff --git a/dom/workers/XMLHttpRequest.cpp b/dom/workers/XMLHttpRequest.cpp index a241f6c0f0c..a15fe20794b 100644 --- a/dom/workers/XMLHttpRequest.cpp +++ b/dom/workers/XMLHttpRequest.cpp @@ -564,17 +564,6 @@ private: MainThreadRun() MOZ_OVERRIDE { mProxy->Teardown(); - - // Make sure to stop the syncLoop of a sync XHR request whose - // worker was released while the request was still running. - if (mProxy->mSyncLoopTarget) { - nsRefPtr runnable = - new MainThreadStopSyncLoopRunnable(mWorkerPrivate, - mProxy->mSyncLoopTarget.forget(), - false); - MOZ_ALWAYS_TRUE(runnable->Dispatch(nullptr)); - } - return NS_OK; } }; @@ -1119,9 +1108,6 @@ LoadStartDetectionRunnable::Run() mProxy->mWorkerPrivate = nullptr; mProxy->mOutstandingSendCount--; } - } else { - // The proxy was released and torn down by a SyncTeardownRunnable. - mProxy->mWorkerPrivate = nullptr; } }