Andrew - Supernews <andrew+nonews@supernews.com> writes:
> On 2006-01-25, Bruce Momjian <pgman@candle.pha.pa.us> wrote:
> > Agreed. 10.1 as 10.0.0.1 is an old behavior which has been removed from
> > most modern versions of networking tools.
On the contrary not only is it still widely used but it is *required* by POSIX
for the relevant functions, inet_aton and getaddrinfo. Note that getaddrinfo
was created from whole cloth by POSIX so there was no backwards compatibility
need for it.
This isn't an obscure old-fashioned thing. People really do use this syntax.
> Indeed so. However the current behaviour has neither the merit of being
> traditional nor the merit of being logical:
Well for networks (cidr datatype) people do frequently refer to things like
10.1/16 and intend it to mean the network prefix. Sure you could argue having
the netmask default to the old class-based addressing is anachronistic but
what other default netmask would you suggest anyways? The only other
reasonable default would be the longest 0-bit suffix which would produce some
odd surprising results like '10.1/16' but '10.2/17'.
--
greg