summaryrefslogtreecommitdiff
path: root/src/lib
diff options
context:
space:
mode:
authormillert <>2003-09-26 16:50:14 +0000
committermillert <>2003-09-26 16:50:14 +0000
commit5dc5747492cf69f33beb7a92abb9ed8c15072b3c (patch)
treedf27d70d74b9f45ea8facb213a59d049d2163592 /src/lib
parent25b92f5cce5fd2ad349851e534e34ebf51ee7b03 (diff)
downloadopenbsd-5dc5747492cf69f33beb7a92abb9ed8c15072b3c.tar.gz
openbsd-5dc5747492cf69f33beb7a92abb9ed8c15072b3c.tar.bz2
openbsd-5dc5747492cf69f33beb7a92abb9ed8c15072b3c.zip
No need to include non-standard machine/endian.h header since
sys/types does that for us. Add a STANDARDS section that says what is and is not standard. OK fgsch@
Diffstat (limited to 'src/lib')
-rw-r--r--src/lib/libc/net/byteorder.316
1 files changed, 13 insertions, 3 deletions
diff --git a/src/lib/libc/net/byteorder.3 b/src/lib/libc/net/byteorder.3
index e3b7972160..19be4d2228 100644
--- a/src/lib/libc/net/byteorder.3
+++ b/src/lib/libc/net/byteorder.3
@@ -1,4 +1,4 @@
1.\" $OpenBSD: byteorder.3,v 1.11 2003/09/21 18:11:27 fgsch Exp $ 1.\" $OpenBSD: byteorder.3,v 1.12 2003/09/26 16:50:14 millert 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.
@@ -48,7 +48,6 @@
48.Nd convert values between different byte orderings 48.Nd convert values between different byte orderings
49.Sh SYNOPSIS 49.Sh SYNOPSIS
50.Fd #include <sys/types.h> 50.Fd #include <sys/types.h>
51.Fd #include <machine/endian.h>
52.Ft u_int32_t 51.Ft u_int32_t
53.Fn htonl "u_int32_t host32" 52.Fn htonl "u_int32_t host32"
54.Ft u_int16_t 53.Ft u_int16_t
@@ -168,12 +167,23 @@ and
168.Sh SEE ALSO 167.Sh SEE ALSO
169.Xr gethostbyname 3 , 168.Xr gethostbyname 3 ,
170.Xr getservent 3 169.Xr getservent 3
170.Sh STANDARDS
171The
172.Fn htonl ,
173.Fn htons ,
174.Fn ntohl ,
175and
176.Fn ntohs
177functions conform to
178.St -p1003.1 .
179The other functions are extensions that should not be used when portability
180is required.
171.Sh HISTORY 181.Sh HISTORY
172The 182The
173.Nm byteorder 183.Nm byteorder
174functions appeared in 184functions appeared in
175.Bx 4.2 . 185.Bx 4.2 .
176.Sh BUGS 186.Sh BUGS
177On the vax, alpha, i386, and so far mips, 187On the vax, alpha, i386, and some mips architectures,
178bytes are handled backwards from most everyone else in the world. 188bytes are handled backwards from most everyone else in the world.
179This is not expected to be fixed in the near future. 189This is not expected to be fixed in the near future.