diff options
author | Suhas Daftuar <sdaftuar@gmail.com> | 2019-03-08 15:48:41 -0500 |
---|---|---|
committer | Suhas Daftuar <sdaftuar@gmail.com> | 2019-09-04 14:58:34 -0400 |
commit | e75c39cd425f8c4e5b6bbb2beecb9c80034fefe1 (patch) | |
tree | 697bd41fb179ec55aaea1ef76f015ade8ac33169 /src/net.h | |
parent | c4aa2ba82211ea5988ed7fe21e1b08bc3367e6d4 (diff) |
Check that tx_relay is initialized before access
Diffstat (limited to 'src/net.h')
-rw-r--r-- | src/net.h | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -848,7 +848,7 @@ public: void AddInventoryKnown(const CInv& inv) { - { + if (m_tx_relay != nullptr) { LOCK(m_tx_relay->cs_tx_inventory); m_tx_relay->filterInventoryKnown.insert(inv.hash); } @@ -856,7 +856,7 @@ public: void PushInventory(const CInv& inv) { - if (inv.type == MSG_TX) { + if (inv.type == MSG_TX && m_tx_relay != nullptr) { LOCK(m_tx_relay->cs_tx_inventory); if (!m_tx_relay->filterInventoryKnown.contains(inv.hash)) { m_tx_relay->setInventoryTxToSend.insert(inv.hash); |