diff options
author | Alexandre Ratchov <ratchov@cvs.openbsd.org> | 2015-12-25 17:16:44 +0000 |
---|---|---|
committer | Alexandre Ratchov <ratchov@cvs.openbsd.org> | 2015-12-25 17:16:44 +0000 |
commit | 4e49d29ef25ced3d9f0dbfd3409e20e4add40c51 (patch) | |
tree | 9e7b2ffcdba0c05483fc04de40de215b62fec420 /usr.bin | |
parent | c32643b5982889916dce10eefe3249e1a60d2e18 (diff) |
Don't set (unused) IPV6_V6ONLY option.
suggested by deraadt
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/sndiod/listen.c | 16 |
1 files changed, 1 insertions, 15 deletions
diff --git a/usr.bin/sndiod/listen.c b/usr.bin/sndiod/listen.c index 1261670a598..c67733886f7 100644 --- a/usr.bin/sndiod/listen.c +++ b/usr.bin/sndiod/listen.c @@ -1,4 +1,4 @@ -/* $OpenBSD: listen.c,v 1.6 2015/12/21 22:03:47 ratchov Exp $ */ +/* $OpenBSD: listen.c,v 1.7 2015/12/25 17:16:43 ratchov Exp $ */ /* * Copyright (c) 2008 Alexandre Ratchov <alex@caoua.org> * @@ -163,20 +163,6 @@ listen_new_tcp(char *addr, unsigned int port) perror("setsockopt"); goto bad_close; } - if (ai->ai_family == AF_INET6) { - /* - * make sure IPv6 sockets are restricted to IPv6 - * addresses because we already use a IP socket - * for IP addresses - */ - opt = 1; - if (setsockopt(s, IPPROTO_IPV6, IPV6_V6ONLY, - &opt, sizeof(int)) < 0) { - perror("setsockopt"); - goto bad_close; - } - } - if (bind(s, ai->ai_addr, ai->ai_addrlen) < 0) { perror("bind"); goto bad_close; |