diff options
| author | Cory Fields <[email protected]> | 2016-12-31 02:05:13 -0500 |
|---|---|---|
| committer | Cory Fields <[email protected]> | 2017-01-04 09:29:14 -0500 |
| commit | 60425870d78cf2bef1fce926ad53f51166c6a3f0 (patch) | |
| tree | 6e41ca4685b242752a777bcfc64f49b30cff96d8 /src/net.cpp | |
| parent | net: only disconnect if fDisconnect has been set (diff) | |
| download | discoin-60425870d78cf2bef1fce926ad53f51166c6a3f0.tar.xz discoin-60425870d78cf2bef1fce926ad53f51166c6a3f0.zip | |
net: wait until the node is destroyed to delete its recv buffer
when vRecvMsg becomes a private buffer, it won't make sense to allow other
threads to mess with it anymore.
Diffstat (limited to 'src/net.cpp')
| -rw-r--r-- | src/net.cpp | 5 |
1 files changed, 0 insertions, 5 deletions
diff --git a/src/net.cpp b/src/net.cpp index 65f1c62ad..9ce7475bc 100644 --- a/src/net.cpp +++ b/src/net.cpp @@ -437,11 +437,6 @@ void CNode::CloseSocketDisconnect() LogPrint("net", "disconnecting peer=%d\n", id); CloseSocket(hSocket); } - - // in case this fails, we'll empty the recv buffer when the CNode is deleted - TRY_LOCK(cs_vRecvMsg, lockRecv); - if (lockRecv) - vRecvMsg.clear(); } void CConnman::ClearBanned() |