summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorjmc <>2003-05-01 19:10:09 +0000
committerjmc <>2003-05-01 19:10:09 +0000
commit4fee542bdc3c7525d3cdec0f32496a4c4c857c2b (patch)
tree136ea65dbdc5dbe9fd99b800986f8865ac130e5e
parentb0b363c41fb5798849f7ca119b2c07c293a9d690 (diff)
downloadopenbsd-4fee542bdc3c7525d3cdec0f32496a4c4c857c2b.tar.gz
openbsd-4fee542bdc3c7525d3cdec0f32496a4c4c857c2b.tar.bz2
openbsd-4fee542bdc3c7525d3cdec0f32496a4c4c857c2b.zip
typos;
ok itojun@
-rw-r--r--src/lib/libc/net/getaddrinfo.322
-rw-r--r--src/lib/libc/net/getnameinfo.316
2 files changed, 19 insertions, 19 deletions
diff --git a/src/lib/libc/net/getaddrinfo.3 b/src/lib/libc/net/getaddrinfo.3
index 5c4be16732..12b5500436 100644
--- a/src/lib/libc/net/getaddrinfo.3
+++ b/src/lib/libc/net/getaddrinfo.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: getaddrinfo.3,v 1.20 2002/04/30 16:31:42 mpech Exp $ 1.\" $OpenBSD: getaddrinfo.3,v 1.21 2003/05/01 19:10:09 jmc Exp $
2.\" $KAME: getaddrinfo.3,v 1.29 2001/02/12 09:24:45 itojun Exp $ 2.\" $KAME: getaddrinfo.3,v 1.29 2001/02/12 09:24:45 itojun Exp $
3.\" 3.\"
4.\" Copyright (c) 1983, 1987, 1991, 1993 4.\" Copyright (c) 1983, 1987, 1991, 1993
@@ -351,32 +351,32 @@ indicate an unknown error.
351The implementation allows experimental numeric IPv6 address notation with 351The implementation allows experimental numeric IPv6 address notation with
352scope identifier. 352scope identifier.
353By appending the percent character and scope identifier to addresses, 353By appending the percent character and scope identifier to addresses,
354you can fill 354you can fill the
355.Li sin6_scope_id 355.Li sin6_scope_id
356field for addresses. 356field for addresses.
357This would make management of scoped address easier, 357This would make management of scoped address easier,
358and allows cut-and-paste input of scoped address. 358and allows cut-and-paste input of scoped address.
359.Pp 359.Pp
360At this moment the code supports only link-local addresses with the format. 360At this moment the code supports only link-local addresses with the format.
361Scope identifier is hardcoded to name of hardware interface associated 361Scope identifier is hardcoded to the name of the hardware interface associated
362with the link. 362with the link.
363.Po 363.Po
364such as 364such as
365.Li ne0 365.Li ne0
366.Pc . 366.Pc .
367Example would be like 367An example is
368.Dq Li fe80::1%ne0 , 368.Dq Li fe80::1%ne0 ,
369which means 369which means
370.Do 370.Do
371.Li fe80::1 371.Li fe80::1
372on the link associated with 372on the link associated with the
373.Li ne0 373.Li ne0
374interface 374interface
375.Dc . 375.Dc .
376.Pp 376.Pp
377The implementation is still very experimental and non-standard. 377The implementation is still very experimental and non-standard.
378The current implementation assumes one-by-one relationship between 378The current implementation assumes a one-to-one relationship between
379interface and link, which is not necessarily true from the specification. 379the interface and link, which is not necessarily true from the specification.
380.\" 380.\"
381.Sh EXAMPLES 381.Sh EXAMPLES
382The following code tries to connect to 382The following code tries to connect to
@@ -384,14 +384,14 @@ The following code tries to connect to
384service 384service
385.Dq Li http . 385.Dq Li http .
386via stream socket. 386via stream socket.
387It loops through all the addresses available, regardless from address family. 387It loops through all the addresses available, regardless of address family.
388If the destination resolves to IPv4 address, it will use 388If the destination resolves to an IPv4 address, it will use
389.Dv AF_INET 389.Dv AF_INET
390socket. 390socket.
391Similarly, if it resolves to IPv6, 391Similarly, if it resolves to IPv6,
392.Dv AF_INET6 392.Dv AF_INET6
393socket is used. 393socket is used.
394Observe that there is no hardcoded reference to particular address family. 394Observe that there is no hardcoded reference to a particular address family.
395The code works even if 395The code works even if
396.Nm getaddrinfo 396.Nm getaddrinfo
397returns addresses that are not IPv4/v6. 397returns addresses that are not IPv4/v6.
@@ -532,8 +532,8 @@ values, the function still returns a pointer to a string whose contents
532indicate an unknown error. 532indicate an unknown error.
533.\" 533.\"
534.Sh SEE ALSO 534.Sh SEE ALSO
535.Xr getnameinfo 3 ,
536.Xr gethostbyname 3 , 535.Xr gethostbyname 3 ,
536.Xr getnameinfo 3 ,
537.Xr getservbyname 3 , 537.Xr getservbyname 3 ,
538.Xr hosts 5 , 538.Xr hosts 5 ,
539.Xr resolv.conf 5 , 539.Xr resolv.conf 5 ,
diff --git a/src/lib/libc/net/getnameinfo.3 b/src/lib/libc/net/getnameinfo.3
index 76c6449906..e151157949 100644
--- a/src/lib/libc/net/getnameinfo.3
+++ b/src/lib/libc/net/getnameinfo.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: getnameinfo.3,v 1.17 2001/11/15 06:53:09 itojun Exp $ 1.\" $OpenBSD: getnameinfo.3,v 1.18 2003/05/01 19:10:09 jmc Exp $
2.\" $KAME: getnameinfo.3,v 1.20 2001/01/05 13:37:37 itojun Exp $ 2.\" $KAME: getnameinfo.3,v 1.20 2001/01/05 13:37:37 itojun Exp $
3.\" 3.\"
4.\" Copyright (c) 1983, 1987, 1991, 1993 4.\" Copyright (c) 1983, 1987, 1991, 1993
@@ -56,11 +56,11 @@ The
56function is defined for protocol-independent address-to-nodename translation. 56function is defined for protocol-independent address-to-nodename translation.
57Its functionality is a reverse conversion of 57Its functionality is a reverse conversion of
58.Xr getaddrinfo 3 , 58.Xr getaddrinfo 3 ,
59and implements similar functionality with 59and implements similar functionality to
60.Xr gethostbyaddr 3 60.Xr gethostbyaddr 3
61and 61and
62.Xr getservbyport 3 62.Xr getservbyport 3
63in more sophisticated manner. 63in a more sophisticated manner.
64.Pp 64.Pp
65This function looks up an IP address and port number provided by the 65This function looks up an IP address and port number provided by the
66caller in the DNS and system-specific database, and returns text 66caller in the DNS and system-specific database, and returns text
@@ -180,16 +180,16 @@ flags are defined in
180.Ss Extension for scoped IPv6 address 180.Ss Extension for scoped IPv6 address
181The implementation allows experimental numeric IPv6 address notation with 181The implementation allows experimental numeric IPv6 address notation with
182scope identifier. 182scope identifier.
183IPv6 link-local address will appear as string like 183IPv6 link-local address will appear as a string like
184.Dq Li fe80::1%ne0 . 184.Dq Li fe80::1%ne0 .
185Refer to 185Refer to
186.Xr getaddrinfo 3 186.Xr getaddrinfo 3
187for the notation. 187for the notation.
188.\" 188.\"
189.Sh EXAMPLES 189.Sh EXAMPLES
190The following code tries to get numeric hostname, and service name, 190The following code tries to get a numeric hostname, and service name,
191for given socket address. 191for given socket address.
192Observe that there is no hardcoded reference to particular address family. 192Observe that there is no hardcoded reference to a particular address family.
193.Bd -literal -offset indent 193.Bd -literal -offset indent
194struct sockaddr *sa; /* input */ 194struct sockaddr *sa; /* input */
195char hbuf[NI_MAXHOST], sbuf[NI_MAXSERV]; 195char hbuf[NI_MAXHOST], sbuf[NI_MAXSERV];
@@ -281,7 +281,7 @@ The implementation first appeared in WIDE Hydrangea IPv6 protocol stack kit.
281.Sh STANDARDS 281.Sh STANDARDS
282The 282The
283.Fn getaddrinfo 283.Fn getaddrinfo
284function is defined IEEE POSIX 1003.1g draft specification, 284function is defined in IEEE POSIX 1003.1g draft specification,
285and documented in 285and documented in
286.Dq Basic Socket Interface Extensions for IPv6 286.Dq Basic Socket Interface Extensions for IPv6
287.Pq RFC2553 . 287.Pq RFC2553 .
@@ -292,6 +292,6 @@ The current implementation is not thread-safe.
292The text was shamelessly copied from RFC2553. 292The text was shamelessly copied from RFC2553.
293.Pp 293.Pp
294.Ox 294.Ox
295intentionally uses different 295intentionally uses a different
296.Dv NI_MAXHOST 296.Dv NI_MAXHOST
297value from what RFC2553 suggests, to avoid buffer length handling mistakes. 297value from what RFC2553 suggests, to avoid buffer length handling mistakes.