Verified Commit 1075a9f1 authored by smayya's avatar smayya Committed by ma1
Browse files

Bug 2045511 - update nsHttpTransaction::Close() handling of...

Bug 2045511 - update nsHttpTransaction::Close() handling of NS_BINDING_RETARGETED.  a=dmeehan DONTBUILD

Original Revision: https://phabricator.services.mozilla.com/D307751

Differential Revision: https://phabricator.services.mozilla.com/D310586
parent 9a4de08f
Loading
Loading
Loading
Loading
+6 −5
Original line number Diff line number Diff line
@@ -1295,6 +1295,12 @@ void nsHttpTransaction::Close(nsresult reason) {
  MaybeCancelFallbackTimer();

  MOZ_ASSERT(OnSocketThread(), "not on socket thread");

  if (mTokenBucketCancel) {
    mTokenBucketCancel->Cancel(reason);
    mTokenBucketCancel = nullptr;
  }

  if (reason == NS_BINDING_RETARGETED) {
    LOG(("  close %p skipped due to ERETARGETED\n", this));
    return;
@@ -1307,11 +1313,6 @@ void nsHttpTransaction::Close(nsresult reason) {

  NotifyTransactionObserver(reason);

  if (mTokenBucketCancel) {
    mTokenBucketCancel->Cancel(reason);
    mTokenBucketCancel = nullptr;
  }

  // report the reponse is complete if not already reported
  if (!mResponseIsComplete) {
    gHttpHandler->ObserveHttpActivityWithArgs(