Mauro Tortonesi <[EMAIL PROTECTED]> writes:

> hi to hrvoje and all, i am still alive ;-) and i am finally catching
> up with the changes you've done at wget ipv6 code. from what i've
> seen so far, it seems that you've done a great job (especially on
> lookup_host and resolve_bind_address and on the transport_map)!!!

Thanks.

> change this code in address_list_contains:
>
>           if (cur->type == IPV4_ADDRESS
>               && (ADDRESS_IPV4_IN_ADDR (cur).s_addr
>                   ==
>                   ADDRESS_IPV4_IN_ADDR (ip).s_addr))
>
> to the more readable:
>
>           if (cur->type == IPV4_ADDRESS
>               && (ADDRESS_IPV4_IN_ADDR (cur).s_addr
>                   == ADDRESS_IPV4_IN_ADDR (ip).s_addr))

The indentation is not accidental.  It's more readable (to me) because
the ADDRESS_* macros are aligned.

> and rename address_list_connected_p to address_list_is_connected.

The "_p" suffix stands for "predicate" comes from the Lisp world, as a
convention to mark boolean function.  There are other examples of it
in Wget.  I guess it's a matter of taste.

Maybe we should concentrate on the contents rather than style.  :-)

> now we have to add the checks for sockaddr_storage in configure.in.
> what about adding this test (taken from nc6):
>
> AC_DEFUN([TYPE_STRUCT_SOCKADDR_STORAGE],[
>   ds6_have_sockaddr_storage=
>   AC_CHECK_TYPES([struct sockaddr_storage],[
>     ds6_have_sockaddr_storage=yes
>   ],[
>     ds6_have_sockaddr_storage=no
>   ],[
> #include <sys/types.h>
> #include <sys/socket.h>
>   ])
>
>   if test "X$ds6_have_sockaddr_storage" = "Xyes"; then :
>     $1
>   else :
>     $2
>   fi
> ])

This check looks good to me.

> #ifndef ENABLE_IPV6
> # ifndef HAVE_SOCKADDR_STORAGE
> #  define sockaddr_storage sockaddr_in
> # endif
> #endif /* ENABLE_IPV6 */
>
> to:
>
> #ifndef ENABLE_IPV6
> # ifndef HAVE_STRUCT_SOCKADDR_STORAGE
> #  define sockaddr_storage sockaddr_in
> # endif
> #endif /* ENABLE_IPV6 */
>
> in connect.h?

OK.

> i would also suggest renaming configure.in to configure.ac...

Sure.  I've never understood the conceptual difference between the two
anyway.  I'm already using AC_PREREQ(2.57)...

Reply via email to