mirror of
https://github.com/wownero/wownero.git
synced 2026-10-17 15:41:44 +02:00
p2p: use connection state to detect duplicate handshakes
This commit is contained in:
@@ -2602,9 +2602,9 @@ namespace nodetool
|
||||
return 1;
|
||||
}
|
||||
|
||||
if(context.peer_id)
|
||||
if(context.handshake_complete())
|
||||
{
|
||||
LOG_WARNING_CC(context, "COMMAND_HANDSHAKE came, but seems that connection already have associated peer_id (double COMMAND_HANDSHAKE?)");
|
||||
LOG_WARNING_CC(context, "COMMAND_HANDSHAKE came, but connection already completed a handshake (double COMMAND_HANDSHAKE?)");
|
||||
drop_connection(context);
|
||||
return 1;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user