From a883af1652239f9428c24133de68fd9bbf7a123c Mon Sep 17 00:00:00 2001 From: Matthias Schiffer Date: Thu, 24 Jan 2013 13:30:44 +0100 Subject: Don't reset peer address on repeated resolves This can lead to handshakes being ignored for an indefinite time. --- src/resolve.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/resolve.c b/src/resolve.c index 02a986d..c01a88f 100644 --- a/src/resolve.c +++ b/src/resolve.c @@ -121,6 +121,8 @@ void fastd_resolve_peer(fastd_context_t *ctx, fastd_peer_t *peer) { ret->hostname_len = hostname_len; memcpy(hostname, peer->config->hostname, hostname_len); + ret->addr = peer->address; + if (write(ctx->resolvewfd, buf, sizeof(buf)) < 0) pr_error_errno(ctx, "can't write resolve return"); -- cgit v1.2.3