On 01/23/09 10:20, Kacheong Poon wrote:
> Michael Schuster wrote:
> 
>> ah ... I'd missed that one. I think we should use it, since that's 
>> precisely what we intend to indicate (unless I missed something else).
> 
> 
> But why?  We have been using the current convention
> since the prototype.  It has not caused any problem.

because the semantics is wrong: according to the comment in the code:

        #define IPPROTO_IPV6    41      /* IPv6 encapsulated in IP */

which is NOT what we want to indicate when we say "ip version 6" (or do we?).

One advantage of using AF_INET* would be that the getaddrinfo(), which we 
currently use to parse IP addresses, uses them, so we can compare that 
information with what users pass in as "ip version" easily, but if you 
object to the use of AF_INET*, then - as you indicated in your earlier mail 
- we should go with IPV4_VERSION/IPV6_VERSION, or follow Erik's suggestion 
to #define our own.

Michael
-- 
Michael Schuster        http://blogs.sun.com/recursion
Recursion, n.: see 'Recursion'

Reply via email to