Re: Possible /etc/hosts parsing bug?

Philippe Strauss (philou@sicel-home-1-4.urbanet.ch)
Mon, 18 Nov 1996 08:58:38 +0100 (MET)


Mike wrote:
>
> I have found something that may be a small parsing bug, but may
> also be within the specs of its functionality... In my hosts file
> I had a few entries:
>
> 172.16.2.1 Atomic.shocking.com
> 172.16.2.2 Nuclear.shocking.com
> 172.16.2.3 Fusion.shocking.com
>
> In an effort to line everything up and make it look pretty I modified the
> previous lines to the following:
>
> 172.016.002.001 Atomic.shocking.com
> 172.016.002.002 Nuclear.shocking.com
> 172.016.002.003 Fusion.shocking.com
>
> Numerically, these have the same values, but when I tried to ping fusion,
> the IP that it was using was 172.14.2.3. When the extra '0's were deleted
> ping worked fine. Is this within the operating specs? Just curious,
>
> Mike Cumings (aka linux-kernel pest)
> mcumings@ecst.csuchico.edu

Not at all, it's just that number with leading zeroe are
meant in *octal*. I spend two days figuring out what was
wrong with my networking setup, when I first connected my
lili box to internet. I was doing the same mistake. :*)

-- 
Philippe Strauss, CH-1092 Belmont

Email: <philippe.strauss@urbanet.ch> Homepage: http://sicel-home-1-4.urbanet.ch