To further this discussion, on linux the IPV6_MINHOPCOUNT is defined in:

linux/ip6.h, which is not included currently and cannot be because of
structure conflict between it and netinet/in.h( which is included ).  There
is a lively discussion here:

http://www.redhat.com/archives/libvir-list/2013-January/msg00891.html

from a few years back about this exact issue.  From what I can tell this
never went anywhere and was just never addressed.

How would the quagga community like to address this issue?

donald

On Wed, May 13, 2015 at 9:41 AM, Donald Sharp <[email protected]>
wrote:

> The #define IPV6_MINHOPCNT define is never defined on any unix platform.
> From what I can tell the original implementation on the linux platform
> was IPV6_MINHOPCNT, when it got accepted into the mainstream kernel
> it was transformed into IPV6_MINHOPCOUNT.  Since we test for the
> define before attempting to use the code it was silently doing nothing
> for a long time.
> ---
>  lib/sockunion.c |    6 +++---
>  1 file changed, 3 insertions(+), 3 deletions(-)
>
> diff --git a/lib/sockunion.c b/lib/sockunion.c
> index 5e6cf68..2505f29 100644
> --- a/lib/sockunion.c
> +++ b/lib/sockunion.c
> @@ -505,13 +505,13 @@ sockopt_minttl (int family, int sock, int minttl)
>        return ret;
>      }
>  #endif /* IP_MINTTL */
> -#ifdef IPV6_MINHOPCNT
> +#ifdef IPV6_MINHOPCOUNT
>    if (family == AF_INET6)
>      {
> -      int ret = setsockopt (sock, IPPROTO_IPV6, IPV6_MINHOPCNT, &minttl,
> sizeof(minttl));
> +      int ret = setsockopt (sock, IPPROTO_IPV6, IPV6_MINHOPCOUNT,
> &minttl, sizeof(minttl));
>        if (ret < 0)
>           zlog (NULL, LOG_WARNING,
> -               "can't set sockopt IPV6_MINHOPCNT to %d on socket %d: %s",
> +               "can't set sockopt IPV6_MINHOPCOUNT to %d on socket %d:
> %s",
>                 minttl, sock, safe_strerror (errno));
>        return ret;
>      }
> --
> 1.7.10.4
>
>
_______________________________________________
Quagga-dev mailing list
[email protected]
https://lists.quagga.net/mailman/listinfo/quagga-dev

Reply via email to