summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoraaron <>2000-12-24 00:31:00 +0000
committeraaron <>2000-12-24 00:31:00 +0000
commitb11608439e707f8c7601b090028e530ea5a1e067 (patch)
tree966934b4f9368fd14deca5be22b83ff9fb439cbd
parent71213d0b131a3545184a31aa671f269eceacad1e (diff)
downloadopenbsd-b11608439e707f8c7601b090028e530ea5a1e067.tar.gz
openbsd-b11608439e707f8c7601b090028e530ea5a1e067.tar.bz2
openbsd-b11608439e707f8c7601b090028e530ea5a1e067.zip
Various repairs, mostly to get rid of short lines.
-rw-r--r--src/lib/libc/net/getaddrinfo.34
-rw-r--r--src/lib/libc/net/gethostbyname.323
-rw-r--r--src/lib/libc/net/getnetent.324
-rw-r--r--src/lib/libc/net/getprotoent.334
-rw-r--r--src/lib/libc/net/getservent.338
-rw-r--r--src/lib/libc/net/rcmd.317
-rw-r--r--src/lib/libc/net/rcmdsh.322
-rw-r--r--src/lib/libc/net/resolver.343
-rw-r--r--src/lib/libc/stdlib/qdiv.35
9 files changed, 73 insertions, 137 deletions
diff --git a/src/lib/libc/net/getaddrinfo.3 b/src/lib/libc/net/getaddrinfo.3
index 747f62b33b..01bfb3cef8 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.12 2000/08/13 07:23:48 deraadt Exp $ 1.\" $OpenBSD: getaddrinfo.3,v 1.13 2000/12/24 00:30:54 aaron Exp $
2.\" $KAME: getaddrinfo.3,v 1.22 2000/08/09 21:16:17 itojun Exp $ 2.\" $KAME: getaddrinfo.3,v 1.22 2000/08/09 21:16:17 itojun Exp $
3.\" 3.\"
4.\" Copyright (c) 1983, 1987, 1991, 1993 4.\" Copyright (c) 1983, 1987, 1991, 1993
@@ -258,7 +258,7 @@ Here are pitfall cases you may encounter:
258.Bl -bullet 258.Bl -bullet
259.It 259.It
260.Fn getaddrinfo 260.Fn getaddrinfo
261will raise error if members in 261will raise error if members in
262.Fa hints 262.Fa hints
263structure is not consistent. 263structure is not consistent.
264For example, for internet address families, 264For example, for internet address families,
diff --git a/src/lib/libc/net/gethostbyname.3 b/src/lib/libc/net/gethostbyname.3
index f1353288c5..94a848eecc 100644
--- a/src/lib/libc/net/gethostbyname.3
+++ b/src/lib/libc/net/gethostbyname.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: gethostbyname.3,v 1.15 2000/04/18 03:01:31 aaron Exp $ 1.\" $OpenBSD: gethostbyname.3,v 1.16 2000/12/24 00:30:56 aaron Exp $
2.\" 2.\"
3.\" Copyright (c) 1983, 1987, 1991, 1993 3.\" Copyright (c) 1983, 1987, 1991, 1993
4.\" The Regents of the University of California. All rights reserved. 4.\" The Regents of the University of California. All rights reserved.
@@ -68,10 +68,8 @@ The
68.Fn gethostbyname 68.Fn gethostbyname
69and 69and
70.Fn gethostbyaddr 70.Fn gethostbyaddr
71functions 71functions each return a pointer to an object with the following structure
72each return a pointer to an object with the 72describing an internet host referenced by name or by address, respectively.
73following structure describing an internet host
74referenced by name or by address, respectively.
75This structure contains either information obtained from the name server (i.e., 73This structure contains either information obtained from the name server (i.e.,
76.Xr resolver 3 74.Xr resolver 3
77and 75and
@@ -140,8 +138,7 @@ The only address family currently supported is
140.Pp 138.Pp
141The 139The
142.Fn sethostent 140.Fn sethostent
143function 141function may be used to request the use of a connected
144may be used to request the use of a connected
145.Tn TCP 142.Tn TCP
146socket for queries. 143socket for queries.
147If the 144If the
@@ -159,8 +156,7 @@ datagrams.
159.Pp 156.Pp
160The 157The
161.Fn endhostent 158.Fn endhostent
162function 159function closes the
163closes the
164.Tn TCP 160.Tn TCP
165connection. 161connection.
166.Pp 162.Pp
@@ -239,13 +235,11 @@ re-opening the file if necessary.
239.Pp 235.Pp
240The 236The
241.Fn sethostent 237.Fn sethostent
242function 238function opens and/or rewinds the file
243opens and/or rewinds the file
244.Pa /etc/hosts . 239.Pa /etc/hosts .
245If the 240If the
246.Fa stayopen 241.Fa stayopen
247argument is non-zero, 242argument is non-zero, the file will not be closed after each call to
248the file will not be closed after each call to
249.Fn gethostbyname , 243.Fn gethostbyname ,
250.Fn gethostbyname2 , 244.Fn gethostbyname2 ,
251or 245or
@@ -253,8 +247,7 @@ or
253.Pp 247.Pp
254The 248The
255.Fn endhostent 249.Fn endhostent
256function 250function closes the file.
257closes the file.
258.Sh HISTORY 251.Sh HISTORY
259The 252The
260.Fn herror 253.Fn herror
diff --git a/src/lib/libc/net/getnetent.3 b/src/lib/libc/net/getnetent.3
index 3227f39b06..0c401c74ff 100644
--- a/src/lib/libc/net/getnetent.3
+++ b/src/lib/libc/net/getnetent.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: getnetent.3,v 1.10 2000/12/17 21:30:38 millert Exp $ 1.\" $OpenBSD: getnetent.3,v 1.11 2000/12/24 00:30:56 aaron Exp $
2.\" 2.\"
3.\" Copyright (c) 1983, 1991, 1993 3.\" Copyright (c) 1983, 1991, 1993
4.\" The Regents of the University of California. All rights reserved. 4.\" The Regents of the University of California. All rights reserved.
@@ -59,11 +59,8 @@ The
59.Fn getnetbyname , 59.Fn getnetbyname ,
60and 60and
61.Fn getnetbyaddr 61.Fn getnetbyaddr
62functions 62functions each return a pointer to an object with the following structure
63each return a pointer to an object with the 63containing the broken-out fields of a line in the network database,
64following structure
65containing the broken-out
66fields of a line in the network database,
67.Pa /etc/networks . 64.Pa /etc/networks .
68.Bd -literal -offset indent 65.Bd -literal -offset indent
69struct netent { 66struct netent {
@@ -90,13 +87,11 @@ Network numbers are returned in machine byte order.
90.Pp 87.Pp
91The 88The
92.Fn getnetent 89.Fn getnetent
93function 90function reads the next line of the file, opening the file if necessary.
94reads the next line of the file, opening the file if necessary.
95.Pp 91.Pp
96The 92The
97.Fn setnetent 93.Fn setnetent
98function 94function opens and rewinds the file.
99opens and rewinds the file.
100If the 95If the
101.Fa stayopen 96.Fa stayopen
102flag is non-zero, 97flag is non-zero,
@@ -107,15 +102,13 @@ or
107.Pp 102.Pp
108The 103The
109.Fn endnetent 104.Fn endnetent
110function 105function closes the file.
111closes the file.
112.Pp 106.Pp
113The 107The
114.Fn getnetbyname 108.Fn getnetbyname
115function
116and 109and
117.Fn getnetbyaddr 110.Fn getnetbyaddr
118search the domain name server if the system is configured to use one. 111functions search the domain name server if the system is configured to use one.
119If the search fails, or no name server is configured, they sequentially 112If the search fails, or no name server is configured, they sequentially
120search from the beginning of the file until a matching net name or 113search from the beginning of the file until a matching net name or
121net address and type is found, or until 114net address and type is found, or until
@@ -127,8 +120,7 @@ Network numbers are supplied in host order.
127.It Pa /etc/networks 120.It Pa /etc/networks
128.El 121.El
129.Sh DIAGNOSTICS 122.Sh DIAGNOSTICS
130Null pointer 123Null pointer (0) returned on
131(0) returned on
132.Dv EOF 124.Dv EOF
133or error. 125or error.
134.Sh SEE ALSO 126.Sh SEE ALSO
diff --git a/src/lib/libc/net/getprotoent.3 b/src/lib/libc/net/getprotoent.3
index 4d1e96e615..1f95529532 100644
--- a/src/lib/libc/net/getprotoent.3
+++ b/src/lib/libc/net/getprotoent.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: getprotoent.3,v 1.7 2000/12/17 21:30:38 millert Exp $ 1.\" $OpenBSD: getprotoent.3,v 1.8 2000/12/24 00:30:56 aaron Exp $
2.\" 2.\"
3.\" Copyright (c) 1983, 1991, 1993 3.\" Copyright (c) 1983, 1991, 1993
4.\" The Regents of the University of California. All rights reserved. 4.\" The Regents of the University of California. All rights reserved.
@@ -59,11 +59,8 @@ The
59.Fn getprotobyname , 59.Fn getprotobyname ,
60and 60and
61.Fn getprotobynumber 61.Fn getprotobynumber
62functions 62functions each return a pointer to an object with the following structure
63each return a pointer to an object with the 63containing the broken-out fields of a line in the network protocol database,
64following structure
65containing the broken-out
66fields of a line in the network protocol database,
67.Pa /etc/protocols . 64.Pa /etc/protocols .
68.Bd -literal -offset indent 65.Bd -literal -offset indent
69.Pp 66.Pp
@@ -86,13 +83,11 @@ The protocol number.
86.Pp 83.Pp
87The 84The
88.Fn getprotoent 85.Fn getprotoent
89function 86function reads the next line of the file, opening the file if necessary.
90reads the next line of the file, opening the file if necessary.
91.Pp 87.Pp
92The 88The
93.Fn setprotoent 89.Fn setprotoent
94function 90function opens and rewinds the file.
95opens and rewinds the file.
96If the 91If the
97.Fa stayopen 92.Fa stayopen
98flag is non-zero, 93flag is non-zero,
@@ -103,24 +98,18 @@ or
103.Pp 98.Pp
104The 99The
105.Fn endprotoent 100.Fn endprotoent
106function 101function closes the file.
107closes the file.
108.Pp 102.Pp
109The 103The
110.Fn getprotobyname 104.Fn getprotobyname
111function
112and 105and
113.Fn getprotobynumber 106.Fn getprotobynumber
114sequentially search from the beginning 107functions sequentially search from the beginning of the file until a
115of the file until a matching 108matching protocol name or protocol number is found, or until
116protocol name or
117protocol number is found,
118or until
119.Dv EOF 109.Dv EOF
120is encountered. 110is encountered.
121.Sh RETURN VALUES 111.Sh RETURN VALUES
122Null pointer 112Null pointer (0) returned on
123(0) returned on
124.Dv EOF 113.Dv EOF
125or error. 114or error.
126.Sh FILES 115.Sh FILES
@@ -140,7 +129,6 @@ and
140functions appeared in 129functions appeared in
141.Bx 4.2 . 130.Bx 4.2 .
142.Sh BUGS 131.Sh BUGS
143These functions use a static data space; 132These functions use a static data space; if the data is needed for future use,
144if the data is needed for future use, it should be 133it should be copied before any subsequent calls overwrite it.
145copied before any subsequent calls overwrite it.
146Only the Internet protocols are currently understood. 134Only the Internet protocols are currently understood.
diff --git a/src/lib/libc/net/getservent.3 b/src/lib/libc/net/getservent.3
index 81ebc40cad..85e0d65352 100644
--- a/src/lib/libc/net/getservent.3
+++ b/src/lib/libc/net/getservent.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: getservent.3,v 1.10 2000/12/17 21:30:38 millert Exp $ 1.\" $OpenBSD: getservent.3,v 1.11 2000/12/24 00:30:56 aaron Exp $
2.\" 2.\"
3.\" Copyright (c) 1983, 1991, 1993 3.\" Copyright (c) 1983, 1991, 1993
4.\" The Regents of the University of California. All rights reserved. 4.\" The Regents of the University of California. All rights reserved.
@@ -59,11 +59,8 @@ The
59.Fn getservbyname , 59.Fn getservbyname ,
60and 60and
61.Fn getservbyport 61.Fn getservbyport
62functions 62functions each return a pointer to an object with the following structure
63each return a pointer to an object with the 63containing the broken-out fields of a line in the network services database,
64following structure
65containing the broken-out
66fields of a line in the network services database,
67.Pa /etc/services . 64.Pa /etc/services .
68.Bd -literal -offset indent 65.Bd -literal -offset indent
69struct servent { 66struct servent {
@@ -84,19 +81,16 @@ A zero-terminated list of alternate names for the service.
84The port number at which the service resides. 81The port number at which the service resides.
85Port numbers are returned in network byte order. 82Port numbers are returned in network byte order.
86.It Fa s_proto 83.It Fa s_proto
87The name of the protocol to use when contacting the 84The name of the protocol to use when contacting the service.
88service.
89.El 85.El
90.Pp 86.Pp
91The 87The
92.Fn getservent 88.Fn getservent
93function 89function reads the next line of the file, opening the file if necessary.
94reads the next line of the file, opening the file if necessary.
95.Pp 90.Pp
96The 91The
97.Fn setservent 92.Fn setservent
98function 93function opens and rewinds the file.
99opens and rewinds the file.
100If the 94If the
101.Fa stayopen 95.Fa stayopen
102flag is non-zero, 96flag is non-zero,
@@ -107,19 +101,15 @@ or
107.Pp 101.Pp
108The 102The
109.Fn endservent 103.Fn endservent
110function 104function closes the file.
111closes the file.
112.Pp 105.Pp
113The 106The
114.Fn getservbyname 107.Fn getservbyname
115and 108and
116.Fn getservbyport 109.Fn getservbyport
117functions 110functions sequentially search from the beginning of the file until a
118sequentially search from the beginning 111matching protocol name or port number (specified in network byte order)
119of the file until a matching 112is found, or until
120protocol name or
121port number (specified in network byte order) is found,
122or until
123.Dv EOF 113.Dv EOF
124is encountered. 114is encountered.
125If a protocol name is also supplied (non-null), 115If a protocol name is also supplied (non-null),
@@ -129,8 +119,7 @@ searches must also match the protocol.
129.It Pa /etc/services 119.It Pa /etc/services
130.El 120.El
131.Sh DIAGNOSTICS 121.Sh DIAGNOSTICS
132Null pointer 122Null pointer (0) returned on
133(0) returned on
134.Dv EOF 123.Dv EOF
135or error. 124or error.
136.Sh SEE ALSO 125.Sh SEE ALSO
@@ -147,7 +136,6 @@ and
147functions appeared in 136functions appeared in
148.Bx 4.2 . 137.Bx 4.2 .
149.Sh BUGS 138.Sh BUGS
150These functions use static data storage; 139These functions use static data storage; if the data is needed for future use,
151if the data is needed for future use, it should be 140it should be copied before any subsequent calls overwrite it.
152copied before any subsequent calls overwrite it.
153Expecting port numbers to fit in a 32-bit quantity is probably naive. 141Expecting port numbers to fit in a 32-bit quantity is probably naive.
diff --git a/src/lib/libc/net/rcmd.3 b/src/lib/libc/net/rcmd.3
index 89457ab859..683f27a4af 100644
--- a/src/lib/libc/net/rcmd.3
+++ b/src/lib/libc/net/rcmd.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: rcmd.3,v 1.22 2000/12/21 22:59:53 deraadt Exp $ 1.\" $OpenBSD: rcmd.3,v 1.23 2000/12/24 00:30:56 aaron Exp $
2.\" 2.\"
3.\" Copyright (c) 1983, 1991, 1993 3.\" Copyright (c) 1983, 1991, 1993
4.\" The Regents of the University of California. All rights reserved. 4.\" The Regents of the University of California. All rights reserved.
@@ -62,8 +62,7 @@
62.Sh DESCRIPTION 62.Sh DESCRIPTION
63The 63The
64.Fn rcmd 64.Fn rcmd
65function 65function is used by the superuser to execute a command on a remote
66is used by the superuser to execute a command on a remote
67machine using an authentication scheme based on reserved 66machine using an authentication scheme based on reserved
68port numbers. 67port numbers.
69If the calling process is not setuid, the 68If the calling process is not setuid, the
@@ -92,8 +91,7 @@ The
92.Fn rresvport 91.Fn rresvport
93and 92and
94.Fn rresvport_af 93.Fn rresvport_af
95functions 94functions return a descriptor to a socket
96return a descriptor to a socket
97with an address in the privileged port space. 95with an address in the privileged port space.
98The 96The
99.Fn iruserok 97.Fn iruserok
@@ -112,8 +110,7 @@ is an address family independent variant of
112.Pp 110.Pp
113The 111The
114.Fn rcmd 112.Fn rcmd
115function 113function looks up the host
116looks up the host
117.Fa *ahost 114.Fa *ahost
118using 115using
119.Xr gethostbyname 3 , 116.Xr gethostbyname 3 ,
@@ -245,16 +242,14 @@ and
245.Sh DIAGNOSTICS 242.Sh DIAGNOSTICS
246The 243The
247.Fn rcmd 244.Fn rcmd
248function 245function returns a valid socket descriptor on success.
249returns a valid socket descriptor on success.
250It returns \-1 on error and prints a diagnostic message on the standard error. 246It returns \-1 on error and prints a diagnostic message on the standard error.
251.Pp 247.Pp
252The 248The
253.Fn rresvport 249.Fn rresvport
254and 250and
255.Fn rresvport_af 251.Fn rresvport_af
256functions 252functions return a valid, bound socket descriptor on success.
257return a valid, bound socket descriptor on success.
258It returns \-1 on error with the global value 253It returns \-1 on error with the global value
259.Va errno 254.Va errno
260set according to the reason for failure. 255set according to the reason for failure.
diff --git a/src/lib/libc/net/rcmdsh.3 b/src/lib/libc/net/rcmdsh.3
index 29a1e4cf63..e0c59efb85 100644
--- a/src/lib/libc/net/rcmdsh.3
+++ b/src/lib/libc/net/rcmdsh.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: rcmdsh.3,v 1.7 2000/02/23 17:28:25 aaron Exp $ 1.\" $OpenBSD: rcmdsh.3,v 1.8 2000/12/24 00:30:56 aaron Exp $
2.\" 2.\"
3.\" Copyright (c) 1983, 1991, 1993 3.\" Copyright (c) 1983, 1991, 1993
4.\" The Regents of the University of California. All rights reserved. 4.\" The Regents of the University of California. All rights reserved.
@@ -44,10 +44,8 @@
44.Sh DESCRIPTION 44.Sh DESCRIPTION
45The 45The
46.Fn rcmdsh 46.Fn rcmdsh
47function 47function is used by normal users to execute a command on a remote machine
48is used by normal users to execute a command on 48using an authentication scheme based on reserved port numbers using
49a remote machine using an authentication scheme based
50on reserved port numbers using
51.Xr rshd 8 49.Xr rshd 8
52or the value of 50or the value of
53.Fa rshprog 51.Fa rshprog
@@ -55,17 +53,15 @@ or the value of
55.Pp 53.Pp
56The 54The
57.Fn rcmdsh 55.Fn rcmdsh
58function 56function looks up the host
59looks up the host
60.Fa *ahost 57.Fa *ahost
61using 58using
62.Xr gethostbyname 3 , 59.Xr gethostbyname 3 ,
63returning \-1 if the host does not exist. 60returning \-1 if the host does not exist.
64Otherwise 61Otherwise
65.Fa *ahost 62.Fa *ahost
66is set to the standard name of the host 63is set to the standard name of the host and a connection is established to
67and a connection is established to a server 64a server residing at the well-known Internet port
68residing at the well-known Internet port
69.Li shell/tcp 65.Li shell/tcp
70(or whatever port is used by 66(or whatever port is used by
71.Fa rshprog ) . 67.Fa rshprog ) .
@@ -74,8 +70,7 @@ The parameter
74is ignored; it is only included to provide an interface similar to 70is ignored; it is only included to provide an interface similar to
75.Xr rcmd 3 . 71.Xr rcmd 3 .
76.Pp 72.Pp
77If the connection succeeds, 73If the connection succeeds, a socket in the
78a socket in the
79.Tn UNIX 74.Tn UNIX
80domain of type 75domain of type
81.Dv SOCK_STREAM 76.Dv SOCK_STREAM
@@ -84,8 +79,7 @@ command as stdin and stdout, and stderr.
84.Sh DIAGNOSTICS 79.Sh DIAGNOSTICS
85The 80The
86.Fn rcmdsh 81.Fn rcmdsh
87function 82function returns a valid socket descriptor on success.
88returns a valid socket descriptor on success.
89It returns \-1 on error and prints a diagnostic message on the standard error. 83It returns \-1 on error and prints a diagnostic message on the standard error.
90.Sh SEE ALSO 84.Sh SEE ALSO
91.Xr rsh 1 , 85.Xr rsh 1 ,
diff --git a/src/lib/libc/net/resolver.3 b/src/lib/libc/net/resolver.3
index 9b2471d823..a5f956f90d 100644
--- a/src/lib/libc/net/resolver.3
+++ b/src/lib/libc/net/resolver.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: resolver.3,v 1.13 2000/01/03 11:51:08 itojun Exp $ 1.\" $OpenBSD: resolver.3,v 1.14 2000/12/24 00:30:57 aaron Exp $
2.\" 2.\"
3.\" Copyright (c) 1985, 1991, 1993 3.\" Copyright (c) 1985, 1991, 1993
4.\" The Regents of the University of California. All rights reserved. 4.\" The Regents of the University of California. All rights reserved.
@@ -108,8 +108,7 @@ Global configuration and state information that is used by the
108resolver routines is kept in the structure 108resolver routines is kept in the structure
109.Li _res . 109.Li _res .
110Most of the values have reasonable defaults and can be ignored. 110Most of the values have reasonable defaults and can be ignored.
111Options 111Options stored in
112stored in
113.Li _res.options 112.Li _res.options
114are defined in 113are defined in
115.Aq Pa resolv.h 114.Aq Pa resolv.h
@@ -142,8 +141,7 @@ Used with
142.Dv RES_USEVC 141.Dv RES_USEVC
143to keep the 142to keep the
144.Tn TCP 143.Tn TCP
145connection open between 144connection open between queries.
146queries.
147This is useful only in programs that regularly do many queries. 145This is useful only in programs that regularly do many queries.
148.Tn UDP 146.Tn UDP
149should be the normal mode used. 147should be the normal mode used.
@@ -180,12 +178,10 @@ The option is not meaningful on
180.Pp 178.Pp
181The 179The
182.Fn res_init 180.Fn res_init
183routine 181routine reads the configuration file (if any; see
184reads the configuration file (if any; see
185.Xr resolv.conf 5 ) 182.Xr resolv.conf 5 )
186to get the default domain name, 183to get the default domain name, search list, and the Internet address
187search list and 184of the local name server(s).
188the Internet address of the local name server(s).
189If no server is configured, the host running 185If no server is configured, the host running
190the resolver is tried. 186the resolver is tried.
191The current domain name is defined by the hostname 187The current domain name is defined by the hostname
@@ -235,8 +231,7 @@ The
235.Fn res_search 231.Fn res_search
236routine makes a query and awaits a response like 232routine makes a query and awaits a response like
237.Fn res_query , 233.Fn res_query ,
238but in addition, it implements the default and search rules 234but in addition, it implements the default and search rules controlled by the
239controlled by the
240.Dv RES_DEFNAMES 235.Dv RES_DEFNAMES
241and 236and
242.Dv RES_DNSRCH 237.Dv RES_DNSRCH
@@ -247,11 +242,9 @@ The remaining routines are lower-level routines used by
247.Fn res_query . 242.Fn res_query .
248The 243The
249.Fn res_mkquery 244.Fn res_mkquery
250function 245function constructs a standard query message and places it in
251constructs a standard query message and places it in
252.Fa buf . 246.Fa buf .
253It returns the size of the query, or \-1 if the query is 247It returns the size of the query, or \-1 if the query is larger than
254larger than
255.Fa buflen . 248.Fa buflen .
256The query type 249The query type
257.Fa op 250.Fa op
@@ -266,21 +259,18 @@ is currently unused but is intended for making update messages.
266.Pp 259.Pp
267The 260The
268.Fn res_send 261.Fn res_send
269routine 262routine sends a pre-formatted query and returns an answer.
270sends a pre-formatted query and returns an answer.
271It will call 263It will call
272.Fn res_init 264.Fn res_init
273if 265if
274.Dv RES_INIT 266.Dv RES_INIT
275is not set, send the query to the local name server, and 267is not set, send the query to the local name server, and
276handle timeouts and retries. 268handle timeouts and retries.
277The length of the reply message is returned, or 269The length of the reply message is returned, or \-1 if there were errors.
278\-1 if there were errors.
279.Pp 270.Pp
280The 271The
281.Fn dn_comp 272.Fn dn_comp
282function 273function compresses the domain name
283compresses the domain name
284.Fa exp_dn 274.Fa exp_dn
285and stores it in 275and stores it in
286.Fa comp_dn . 276.Fa comp_dn .
@@ -289,8 +279,7 @@ The size of the array pointed to by
289.Fa comp_dn 279.Fa comp_dn
290is given by 280is given by
291.Fa length . 281.Fa length .
292The compression uses 282The compression uses an array of pointers
293an array of pointers
294.Fa dnptrs 283.Fa dnptrs
295to previously compressed names in the current message. 284to previously compressed names in the current message.
296The first pointer points 285The first pointer points
@@ -300,8 +289,7 @@ The limit to the array is specified by
300.Fa lastdnptr . 289.Fa lastdnptr .
301A side effect of 290A side effect of
302.Fn dn_comp 291.Fn dn_comp
303is to update the list of pointers for 292is to update the list of pointers for labels inserted into the message
304labels inserted into the message
305as the name is compressed. 293as the name is compressed.
306If 294If
307.Em dnptr 295.Em dnptr
@@ -316,8 +304,7 @@ the list of labels is not updated.
316.Pp 304.Pp
317The 305The
318.Fn dn_expand 306.Fn dn_expand
319entry 307entry expands the compressed domain name
320expands the compressed domain name
321.Fa comp_dn 308.Fa comp_dn
322to a full domain name 309to a full domain name
323The compressed name is contained in a query or reply message; 310The compressed name is contained in a query or reply message;
diff --git a/src/lib/libc/stdlib/qdiv.3 b/src/lib/libc/stdlib/qdiv.3
index 127c581250..4db47d9b4a 100644
--- a/src/lib/libc/stdlib/qdiv.3
+++ b/src/lib/libc/stdlib/qdiv.3
@@ -33,7 +33,7 @@
33.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF 33.\" OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
34.\" SUCH DAMAGE. 34.\" SUCH DAMAGE.
35.\" 35.\"
36.\" $OpenBSD: qdiv.3,v 1.3 1999/06/29 18:36:21 aaron Exp $ 36.\" $OpenBSD: qdiv.3,v 1.4 2000/12/24 00:31:00 aaron Exp $
37.\" 37.\"
38.Dd June 29, 1991 38.Dd June 29, 1991
39.Dt QDIV 3 39.Dt QDIV 3
@@ -48,8 +48,7 @@
48.Sh DESCRIPTION 48.Sh DESCRIPTION
49The 49The
50.Fn qdiv 50.Fn qdiv
51function 51function computes the value
52computes the value
53.Fa num Ns No / Ns Fa denom 52.Fa num Ns No / Ns Fa denom
54and returns the quotient and remainder in a structure named 53and returns the quotient and remainder in a structure named
55.Li qdiv_t 54.Li qdiv_t