From: Guus Sliepen Date: Sun, 5 Jun 2016 13:20:57 +0000 (+0200) Subject: Fix the previous commit. X-Git-Tag: release-1.1pre15~69 X-Git-Url: https://tinc-vpn.org/git/browse?a=commitdiff_plain;h=74eb4cc974f6d24370f439a1761dc4412d7fa58d;p=tinc Fix the previous commit. --- diff --git a/src/protocol_auth.c b/src/protocol_auth.c index 65c5e89e..31b1f1e7 100644 --- a/src/protocol_auth.c +++ b/src/protocol_auth.c @@ -866,7 +866,8 @@ bool ack_h(connection_t *c, const char *request) { c->edge = new_edge(); c->edge->from = myself; c->edge->to = n; - sockaddr_setport(&c->address, hisport); + sockaddrcpy(&c->edge->address, &c->address); + sockaddr_setport(&c->edge->address, hisport); sockaddr_t local_sa; socklen_t local_salen = sizeof local_sa; if (getsockname(c->socket, &local_sa.sa, &local_salen) < 0)