summaryrefslogtreecommitdiff
path: root/src/udp.c
diff options
context:
space:
mode:
authorAlex Harpin <development@landsofshadow.co.uk>2015-10-02 07:43:42 +0100
committerAlex Harpin <development@landsofshadow.co.uk>2015-10-02 07:43:42 +0100
commitef5ae91676c8ada2a12ea72f889a54452dd94981 (patch)
tree0a962905ab9d0c2322f627928521a10c4cb5e20f /src/udp.c
parent9f9a63cecdc6ac4f449d3eacda6c591f0de9fbf3 (diff)
parent8845f3db20c951fcf1db3229a818cfd185f17f2e (diff)
downloadconntrack-tools-ef5ae91676c8ada2a12ea72f889a54452dd94981.tar.gz
conntrack-tools-ef5ae91676c8ada2a12ea72f889a54452dd94981.zip
Merge remote-tracking branch 'source/master' into upstreamupstream
Diffstat (limited to 'src/udp.c')
-rw-r--r--src/udp.c8
1 files changed, 6 insertions, 2 deletions
diff --git a/src/udp.c b/src/udp.c
index ecaa46e..d0a7f5b 100644
--- a/src/udp.c
+++ b/src/udp.c
@@ -136,14 +136,18 @@ struct udp_sock *udp_client_create(struct udp_conf *conf)
m->addr.ipv4.sin_family = AF_INET;
m->addr.ipv4.sin_port = htons(conf->port);
m->addr.ipv4.sin_addr = conf->client.inet_addr;
- m->sockaddr_len = sizeof(struct sockaddr_in);
+ m->sockaddr_len = sizeof(struct sockaddr_in);
break;
case AF_INET6:
m->addr.ipv6.sin6_family = AF_INET6;
m->addr.ipv6.sin6_port = htons(conf->port);
memcpy(&m->addr.ipv6.sin6_addr, &conf->client.inet_addr6,
sizeof(struct in6_addr));
- m->sockaddr_len = sizeof(struct sockaddr_in6);
+ m->sockaddr_len = sizeof(struct sockaddr_in6);
+ /* Bind the sender side to the same interface that we use to
+ * receive sync messages.
+ */
+ m->addr.ipv6.sin6_scope_id = conf->server.ipv6.scope_id;
break;
default:
ret = -1;