aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authormoneromooo-monero <moneromooo-monero@users.noreply.github.com>2018-11-26 17:19:25 +0000
committermoneromooo-monero <moneromooo-monero@users.noreply.github.com>2018-11-26 17:19:25 +0000
commit506472e0c6a1961ada5e1e68ff10def760e4316f (patch)
treedf8eb356330a89941ae37d002390a2f8b5f81251 /src
parentMerge pull request #4781 (diff)
downloadmonero-506472e0c6a1961ada5e1e68ff10def760e4316f.tar.xz
protocol: fix use after free when dropping a connection
Diffstat (limited to 'src')
-rw-r--r--src/cryptonote_protocol/cryptonote_protocol_handler.inl4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/cryptonote_protocol/cryptonote_protocol_handler.inl b/src/cryptonote_protocol/cryptonote_protocol_handler.inl
index c2c660e8c..1a26e7ee8 100644
--- a/src/cryptonote_protocol/cryptonote_protocol_handler.inl
+++ b/src/cryptonote_protocol/cryptonote_protocol_handler.inl
@@ -1738,9 +1738,9 @@ skip:
if (add_fail)
m_p2p->add_host_fail(context.m_remote_address);
- m_p2p->drop_connection(context);
-
m_block_queue.flush_spans(context.m_connection_id, flush_all_spans);
+
+ m_p2p->drop_connection(context);
}
//------------------------------------------------------------------------------------------------------------------------
template<class t_core>