diff --git a/src/main.cpp b/src/main.cpp index 72d9a3d44..6d006e878 100644 --- a/src/main.cpp +++ b/src/main.cpp @@ -5725,6 +5725,9 @@ bool SendMessages(CNode* pto) pto->vAddrToSend.clear(); if (!vAddr.empty()) pto->PushMessage(NetMsgType::ADDR, vAddr); + // we only send the big addr message once + if (pto->vAddrToSend.capacity() > 40) + pto->vAddrToSend.shrink_to_fit(); } CNodeState &state = *State(pto->GetId());