From owner-FreeBSD-users-jp@jp.freebsd.org  Sun Mar  2 15:37:14 1997
Received: by jaz.jp.freebsd.org (8.8.5+2.7Wbeta5/8.7.3) id PAA12884
	Sun, 2 Mar 1997 15:37:14 +0900 (JST)
Received: by jaz.jp.freebsd.org (8.8.5+2.7Wbeta5/8.7.3) with ESMTP id PAA12879
	for <FreeBSD-users-jp@jp.freebsd.org>; Sun, 2 Mar 1997 15:37:13 +0900 (JST)
Received: from unicorn.netlab.is.tsukuba.ac.jp (unicorn.netlab.is.tsukuba.ac.jp [130.158.85.5]) by unicorn.netlab.is.tsukuba.ac.jp (8.8.5/3.5Wpl1netlab-5.01) with SMTP id PAA08654 for FreeBSD-users-jp@jp.freebsd.org; Sun, 2 Mar 1997 15:37:12 +0900 (JST)
Date: Sun, 2 Mar 1997 15:37:12 +0900 (JST)
Message-Id: <199703020637.PAA08654@unicorn.netlab.is.tsukuba.ac.jp>
To: FreeBSD-users-jp@jp.freebsd.org
From: ush@netlab.is.tsukuba.ac.jp (=?ISO-2022-JP?B?GyRCNW06LBsoQiAbJEI5KDksGyhC?=)
Mime-Version: 1.0
Content-Type: text/plain; charset=ISO-2022-JP
X-Mailer: mnews [version 1.20] 1996-12/08(Sun)
Reply-To: FreeBSD-users-jp@jp.freebsd.org
Precedence: bulk
X-Distribute: distribute [version 2.1 (Alpha) patchlevel=19]
X-Sequence: FreeBSD-users-jp 10260
Subject: [FreeBSD-users-jp 10260] Can't use hexdecimal style IP address in /etc/hosts.
Errors-To: owner-FreeBSD-users-jp@jp.freebsd.org
Sender: owner-FreeBSD-users-jp@jp.freebsd.org

$B5m:,!wC^GHBg3X%M%C%H%o!<%/8&$G$9!%(B

3.0-SNAP $B$r;H$C$F$$$F5$$E$$$?$3$H$J$s$G$9$,!$(B
hosts $B$K(B $B#1#6?JI=5-$7$?(B IP$B%"%I%l%9$r=q$$$F$bFI$_9~$s$G$/$l$J$$$3$H$,(B
$BJ,$+$j$^$7$?$N$G!$$A$g$C$HD4$Y$F8+$^$7$?!%(B

$B$^$:(B man hosts $B$G$9$,!$(Binet_addr $B$N=hM}7A<0$G$h$$$H$J$C$F$$$^$9!%(B
$B<!$K(B man inet  $B$G$9$,(B,
INTERNET ADDRESSES
     Values specified using the `.' notation take one of the following forms:

           a.b.c.d
           a.b.c
           a.b
           a
$B$G(B
     All numbers supplied as ``parts'' in a `.' notation may be decimal, oc-
     tal, or hexadecimal, as specified in the C language (i.e., a leading 0x
     or 0X implies hexadecimal; otherwise, a leading 0 implies octal; other-
     wise, the number is interpreted as decimal).
$B$H$J$C$F$*$j(B hexdecimal, octal $B$G$b$h$$$3$H$K$J$C$F$$$^$9!%(B

$B$=$3$G(B libc $B$N(B gethostbyaddr $B$N(B $B2<@A$1$N(B gethostbyht.c $B$rD/$a$k$H(B
2.1.7-R $B$G$O(B $BFI$_9~$s$@J8;zNs$r(B inet_addr $B$KEO$7$F$$$^$9$,(B
2.2 $B0J9_$G$O(B $BFI$_9~$s$@J8;zNs$r(B IPv6$B$r=hM}$9$k$?$a$K(B inet_pton $B$K(B
$BEO$7$F$$$^$9!%(B

inet_pton $B$O(B inet_pton4() $B$H(B inet_pton6() $B$KJ,$+$l$F$*$j(B
inet_pton6$B$O(B hexdecimal$B$b=hM}$G$-$k$N$G$9$,(B inet_pton4 $B$O(B
/* int
 * inet_pton4(src, dst)
 *      like inet_aton() but without all the hexadecimal and shorthand.
 * return:
 *      1 if `src' is a valid dotted quad, else 0.
 * notice:
 *      does not touch `dst' unless it's returning 1.
 * author:
 *      Paul Vixie, 1996.
 */
$B$H$J$C$F$$$F(B $B;EMM$H$7$F(B hexdecimal $B$b(B shorthand $B$bG'$a$F$$$^$;$s!%(B

$B$A$J$_$K(B inet_addr $B$H$$$&$+(B inet_aton $B$O$A$c$s$H(B OK $B$G$9!%(B

$B$=$3$G!$<ALd$J$N$G$9$,(B
$B$J$<!$$3$&$$$&;EMM$KJQ99$5$l$?$N$G$7$g$&$+!)(B

    _/|     _/ _/_/_/_/  _/_/_/_/_/ $BC^GHBg3X(B $B%3%s%T%e!<%?%M%C%H%o!<%/8&5f<<(B 
   _/ |    _/ _/            _/         $B5m:,(B $B9(9,(B [Ushine Hiroyuki]
  _/  |   _/ _/_/_/        _/       mail: ush@netlab.is.tsukuba.ac.jp
 _/   |  _/ _/_           _/        http://www.netlab.is.tsukuba.ac.jp/~ush
_/    |__/ _/_/_/_/      _/         Tel : 0298-53-5158   Fax : 0298-53-5158
