Mailing List Archive


[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [tlug] Problems with au ADSL/network setup



On Mon, Dec 9, 2013 at 7:38 AM, David J Iannucci
<jlinux@example.com> wrote:
>> Me: "Well, you see, there's some weirdness in the way that Unix
>> interprets numbers and when you put leading zeroes into addresses
>> (e.g. 010.010.100.101) it interprets those parts with leading zeros as
>> octal and the numbers aren't what you think they are."
>
> That sounds like broken software to me. I've never seen an IP
> address in such a format ("dotted octal"?), and I've been around the
> UNIX and TCP/IP world a rather long time (though it sounds like not
> as long as you :=).
>
> When written in the dotted notation, it's always supposed to be
> decimal, no?
>
Not exactly sure this is so, have a look at glibc source about resolving names:
https://sourceware.org/git/?p=glibc.git;a=blob;f=resolv/inet_addr.c;h=144b87a74c1aef62779862e78e5f87e18e66ee9e;hb=f1a24198af04ad3d0ebc9dffde454beb19ed0804#l132

I think I've seem similar behavior in some other place, but didn't
expect it in /etc/hosts :-)
Kalin.


Home | Main Index | Thread Index

Home Page Mailing List Linux and Japan TLUG Members Links