aboutsummaryrefslogtreecommitdiff
path: root/src/p2p/net_node_common.h
diff options
context:
space:
mode:
authormoneromooo-monero <moneromooo-monero@users.noreply.github.com>2020-12-04 13:32:32 +0000
committermoneromooo-monero <moneromooo-monero@users.noreply.github.com>2020-12-06 12:40:07 +0000
commit281b42a281f275b5cc4a5c49336a94cedd0e3ae5 (patch)
tree849efc84a8f2476de396414a6ab055e635cca048 /src/p2p/net_node_common.h
parentMerge pull request #7058 (diff)
downloadmonero-281b42a281f275b5cc4a5c49336a94cedd0e3ae5.tar.xz
p2p: fix race condition accessing a deleted context
Diffstat (limited to '')
-rw-r--r--src/p2p/net_node_common.h4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/p2p/net_node_common.h b/src/p2p/net_node_common.h
index 2ace5987f..f1490a0db 100644
--- a/src/p2p/net_node_common.h
+++ b/src/p2p/net_node_common.h
@@ -58,7 +58,7 @@ namespace nodetool
virtual uint64_t get_public_connections_count()=0;
virtual void for_each_connection(std::function<bool(t_connection_context&, peerid_type, uint32_t)> f)=0;
virtual bool for_connection(const boost::uuids::uuid&, std::function<bool(t_connection_context&, peerid_type, uint32_t)> f)=0;
- virtual bool block_host(const epee::net_utils::network_address &address, time_t seconds = 0)=0;
+ virtual bool block_host(epee::net_utils::network_address address, time_t seconds = 0)=0;
virtual bool unblock_host(const epee::net_utils::network_address &address)=0;
virtual std::map<std::string, time_t> get_blocked_hosts()=0;
virtual std::map<epee::net_utils::ipv4_network_subnet, time_t> get_blocked_subnets()=0;
@@ -108,7 +108,7 @@ namespace nodetool
{
return false;
}
- virtual bool block_host(const epee::net_utils::network_address &address, time_t seconds)
+ virtual bool block_host(epee::net_utils::network_address address, time_t seconds)
{
return true;
}