aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--include/salticidae/network.h2
1 files changed, 1 insertions, 1 deletions
diff --git a/include/salticidae/network.h b/include/salticidae/network.h
index 09b85a0..b269acc 100644
--- a/include/salticidae/network.h
+++ b/include/salticidae/network.h
@@ -620,7 +620,7 @@ bool PeerNetwork<O, _, __>::check_new_conn(const conn_t &conn, uint16_t port) {
{ /* found an unknown peer */
const auto &addr = conn->get_addr();
this->user_tcall->async_call([this, id](ThreadCall::Handle &) {
- unknown_peer_cb(id);
+ if (unknown_peer_cb) unknown_peer_cb(id);
});
if (allow_unknown_peer)
{