diff options
author | Cory Fields <cory-nospam-@coryfields.com> | 2016-12-31 02:05:13 -0500 |
---|---|---|
committer | Cory Fields <cory-nospam-@coryfields.com> | 2017-01-04 09:29:14 -0500 |
commit | 60425870d78cf2bef1fce926ad53f51166c6a3f0 (patch) | |
tree | 6e41ca4685b242752a777bcfc64f49b30cff96d8 | |
parent | f6315e07f9383f3f43e37ada0d6a835810d610b9 (diff) |
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.
-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 65f1c62ad6..9ce7475bc5 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() |