diff --git a/src/p2p_server.cpp b/src/p2p_server.cpp index c68bcfb..50bcdaf 100644 --- a/src/p2p_server.cpp +++ b/src/p2p_server.cpp @@ -380,6 +380,10 @@ void P2PServer::broadcast(const PoolBlock& block) m_broadcastQueue.push_back(data); } + if (uv_is_closing(reinterpret_cast(&m_broadcastAsync))) { + return; + } + const int err = uv_async_send(&m_broadcastAsync); if (err) { LOGERR(1, "uv_async_send failed, error " << uv_err_name(err));