New endpoint is already set in WgPeer::ParseMessageHandshakeResponse

This commit is contained in:
Ludvig Strigeus 2018-11-21 22:49:39 +01:00
parent a03980e74b
commit 0c0e6e1398

View file

@ -1026,8 +1026,6 @@ void WireguardProcessor::HandleHandshakeResponsePacket(Packet *packet) {
if (peer) {
stats_.handshakes_out_success++;
WG_SCOPED_LOCK(peer->mutex_);
if (peer->allow_endpoint_change_ && packet->addr.sin.sin_family != 0)
peer->endpoint_ = packet->addr;
peer->OnHandshakeAuthComplete();
peer->OnHandshakeFullyComplete();
NotifyHandshakeComplete();