Bug 1231975 - Part 2: Break a reference cycle between NrTcpSocketIpc and TCPSocketChild, in the same manner as the UDP case. r=mcmanus
☠☠ backed out by a8d0cda0ef76 ☠ ☠
authorByron Campen [:bwc] <docfaraday@gmail.com>
Thu, 07 Apr 2016 12:51:59 -0500
changeset 333967 29dce05596c6c854af6f2e71fdfde138033ac1a3
parent 333966 ae1dc75009e73744bc3686a427d985e4e59dd24f
child 333968 7092e498ac3af20998b35a7cadfff4c03d396378
push id6249
push userjlund@mozilla.com
push dateMon, 01 Aug 2016 13:59:36 +0000
treeherdermozilla-beta@bad9d4f5bf7e [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersmcmanus
bugs1231975
milestone49.0a1
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
Bug 1231975 - Part 2: Break a reference cycle between NrTcpSocketIpc and TCPSocketChild, in the same manner as the UDP case. r=mcmanus MozReview-Commit-ID: FNscaNoeloU
dom/network/TCPSocketChild.cpp
--- a/dom/network/TCPSocketChild.cpp
+++ b/dom/network/TCPSocketChild.cpp
@@ -122,16 +122,17 @@ TCPSocketChild::SendWindowlessOpenBind(n
                                 aUseSSL, true, mFilterName);
 }
 
 void
 TCPSocketChildBase::ReleaseIPDLReference()
 {
   MOZ_ASSERT(mIPCOpen);
   mIPCOpen = false;
+  mSocket = nullptr;
   this->Release();
 }
 
 void
 TCPSocketChildBase::AddIPDLReference()
 {
   MOZ_ASSERT(!mIPCOpen);
   mIPCOpen = true;