Skip to content

Commit

Permalink
Backed out changeset 9c3f8e19266c (bug 1635092) as requested by the d…
Browse files Browse the repository at this point in the history
…ev. a=backout
  • Loading branch information
Pascal Chevrel committed Jun 9, 2022
1 parent f177a19 commit c9bda5c
Show file tree
Hide file tree
Showing 4 changed files with 9 additions and 129 deletions.
79 changes: 0 additions & 79 deletions netwerk/base/ExecuteIfOnMainThreadEventTarget.cpp

This file was deleted.

37 changes: 0 additions & 37 deletions netwerk/base/ExecuteIfOnMainThreadEventTarget.h

This file was deleted.

2 changes: 0 additions & 2 deletions netwerk/base/moz.build
Original file line number Diff line number Diff line change
Expand Up @@ -159,7 +159,6 @@ EXPORTS.mozilla.net += [
"Dashboard.h",
"DashboardTypes.h",
"DefaultURI.h",
"ExecuteIfOnMainThreadEventTarget.h",
"IOActivityMonitor.h",
"MemoryDownloader.h",
"NetworkConnectivityService.h",
Expand All @@ -179,7 +178,6 @@ UNIFIED_SOURCES += [
"Dashboard.cpp",
"DefaultURI.cpp",
"EventTokenBucket.cpp",
"ExecuteIfOnMainThreadEventTarget.cpp",
"IOActivityMonitor.cpp",
"LoadContextInfo.cpp",
"LoadInfo.cpp",
Expand Down
20 changes: 9 additions & 11 deletions netwerk/protocol/http/HttpChannelParent.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,6 @@
#include "mozilla/dom/ServiceWorkerUtils.h"
#include "mozilla/dom/BrowserParent.h"
#include "mozilla/net/NeckoParent.h"
#include "mozilla/net/ExecuteIfOnMainThreadEventTarget.h"
#include "mozilla/InputStreamLengthHelper.h"
#include "mozilla/IntegerPrintfMacros.h"
#include "mozilla/ProfilerLabels.h"
Expand Down Expand Up @@ -62,7 +61,8 @@ using mozilla::BasePrincipal;
using namespace mozilla::dom;
using namespace mozilla::ipc;

namespace mozilla::net {
namespace mozilla {
namespace net {

HttpChannelParent::HttpChannelParent(dom::BrowserParent* iframeEmbedding,
nsILoadContext* aLoadContext,
Expand Down Expand Up @@ -560,9 +560,7 @@ bool HttpChannelParent::DoAsyncOpen(
RefPtr<HttpChannelParent> self = this;
WaitForBgParent()
->Then(
ExecuteIfOnMainThreadEventTarget::
GetExecuteIfOnMainThreadEventTarget(),
__func__,
GetMainThreadSerialEventTarget(), __func__,
[self]() {
self->mRequest.Complete();
self->TryInvokeAsyncOpen(NS_OK);
Expand Down Expand Up @@ -644,9 +642,8 @@ bool HttpChannelParent::ConnectChannel(const uint32_t& registrarId) {
RefPtr<HttpChannelParent> self = this;
WaitForBgParent()
->Then(
ExecuteIfOnMainThreadEventTarget::
GetExecuteIfOnMainThreadEventTarget(),
__func__, [self]() { self->mRequest.Complete(); },
GetMainThreadSerialEventTarget(), __func__,
[self]() { self->mRequest.Complete(); },
[self](const nsresult& aResult) {
NS_ERROR("failed to establish the background channel");
self->mRequest.Complete();
Expand Down Expand Up @@ -883,8 +880,8 @@ HttpChannelParent::ContinueVerification(
// Otherwise, wait for the background channel.
nsCOMPtr<nsIAsyncVerifyRedirectReadyCallback> callback = aCallback;
WaitForBgParent()->Then(
ExecuteIfOnMainThreadEventTarget::GetExecuteIfOnMainThreadEventTarget(),
__func__, [callback]() { callback->ReadyToVerify(NS_OK); },
GetMainThreadSerialEventTarget(), __func__,
[callback]() { callback->ReadyToVerify(NS_OK); },
[callback](const nsresult& aResult) {
NS_ERROR("failed to establish the background channel");
callback->ReadyToVerify(aResult);
Expand Down Expand Up @@ -2011,4 +2008,5 @@ void HttpChannelParent::SetCookie(nsCString&& aCookie) {
mCookie = std::move(aCookie);
}

} // namespace mozilla::net
} // namespace net
} // namespace mozilla

0 comments on commit c9bda5c

Please sign in to comment.