diff options
author | Ondrej Zajicek <santiago@crfreenet.org> | 2009-06-18 19:20:07 +0200 |
---|---|---|
committer | Ondrej Zajicek <santiago@crfreenet.org> | 2009-06-18 19:20:07 +0200 |
commit | 789772ed4586213d6a7fbb867b9296a01ce1b9c0 (patch) | |
tree | 52ba2a4a50a3ddce85a13d219446691edda280d8 /sysdep/unix | |
parent | 1b3b3e34ecbc281a13d4ca0b99e891ee9c4d5cac (diff) | |
download | bird-789772ed4586213d6a7fbb867b9296a01ce1b9c0.tar bird-789772ed4586213d6a7fbb867b9296a01ce1b9c0.zip |
Implements option that changes BGP listening socket parametres.
Diffstat (limited to 'sysdep/unix')
-rw-r--r-- | sysdep/unix/io.c | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/sysdep/unix/io.c b/sysdep/unix/io.c index 50992fb..58aed4e 100644 --- a/sysdep/unix/io.c +++ b/sysdep/unix/io.c @@ -703,7 +703,13 @@ sk_setup(sock *s) if ((s->tos >= 0) && setsockopt(fd, SOL_IP, IP_TOS, &s->tos, sizeof(s->tos)) < 0) WARN("IP_TOS"); #endif - + +#ifdef IPV6 + int v = 1; + if ((s->flags & SKF_V6ONLY) && setsockopt(fd, IPPROTO_IPV6, IPV6_V6ONLY, &v, sizeof(v)) < 0) + WARN("IPV6_V6ONLY"); +#endif + if (s->ttl >= 0) err = sk_set_ttl_int(s); else |