File tree Expand file tree Collapse file tree 2 files changed +3
-0
lines changed
Expand file tree Collapse file tree 2 files changed +3
-0
lines changed Original file line number Diff line number Diff line change @@ -884,6 +884,7 @@ class CNode
884884
885885 void AddAddressKnown (const CAddress& _addr)
886886 {
887+ assert (m_addr_known);
887888 m_addr_known->insert (_addr.GetKey ());
888889 }
889890
@@ -892,6 +893,7 @@ class CNode
892893 // Known checking here is only to save space from duplicates.
893894 // SendMessages will filter it again for knowns that were added
894895 // after addresses were pushed.
896+ assert (m_addr_known);
895897 if (_addr.IsValid () && !m_addr_known->contains (_addr.GetKey ())) {
896898 if (vAddrToSend.size () >= MAX_ADDR_TO_SEND) {
897899 vAddrToSend[insecure_rand.randrange (vAddrToSend.size ())] = _addr;
Original file line number Diff line number Diff line change @@ -3561,6 +3561,7 @@ bool PeerLogicValidation::SendMessages(CNode* pto)
35613561 pto->nNextAddrSend = PoissonNextSend (nNow, AVG_ADDRESS_BROADCAST_INTERVAL);
35623562 std::vector<CAddress> vAddr;
35633563 vAddr.reserve (pto->vAddrToSend .size ());
3564+ assert (pto->m_addr_known );
35643565 for (const CAddress& addr : pto->vAddrToSend )
35653566 {
35663567 if (!pto->m_addr_known ->contains (addr.GetKey ()))
You can’t perform that action at this time.
0 commit comments