On Montag, 6. März 2017 16:45:57 CET Gisle Vanem wrote:
> Just a detail, but in src/mswindows.c, there is:
> 
>   #ifdef ENABLE_IPV6
>   /* An inet_ntop implementation that uses WSAAddressToString.
>      Prototype complies with POSIX 1003.1-2004.  This is only used under
>      IPv6 because Wget prints IPv4 addresses using inet_ntoa.  */
> 
> This is wrong since 1) inet_ntoa() is no longer used. And 2) since
> inet_ntop() is used for IPv4 too, 'ENABLE_IPV6' should then become
> '!defined(HAVE_INET_NTOP)'. Thus:
> 
> @@ -572,10 +572,10 @@
>  }
> 
> 
> -#ifdef ENABLE_IPV6
> +#if !defined(HAVE_INET_NTOP)
>  /* An inet_ntop implementation that uses WSAAddressToString.
> -   Prototype complies with POSIX 1003.1-2004.  This is only used under
> -   IPv6 because Wget prints IPv4 addresses using inet_ntoa.  */
> +   Prototype complies with POSIX 1003.1-2004.  This is used
> +   for both IPv4 and IPv6.  */
> 
>  const char *
>  inet_ntop (int af, const void *src, char *dst, socklen_t cnt)

inet_ntop should be covered by gnulib, also for mswindows. What about removing 
inet_ntop from mswindows.c ? Does it compile and work ?

Tim

Attachment: signature.asc
Description: This is a digitally signed message part.

Reply via email to