summaryrefslogtreecommitdiffstats
path: root/sys/netinet/in.h
diff options
context:
space:
mode:
Diffstat (limited to 'sys/netinet/in.h')
-rw-r--r--sys/netinet/in.h17
1 files changed, 10 insertions, 7 deletions
diff --git a/sys/netinet/in.h b/sys/netinet/in.h
index cfd55ca..819a827 100644
--- a/sys/netinet/in.h
+++ b/sys/netinet/in.h
@@ -498,6 +498,16 @@ char *inet_ntoa_r __P((struct in_addr ina, char *buf)); /* in libkern */
#else /* !_KERNEL */
+#ifndef _BYTEORDER_PROTOTYPED
+#define _BYTEORDER_PROTOTYPED
+__BEGIN_DECLS
+__uint32_t htonl __P((__uint32_t));
+__uint16_t htons __P((__uint16_t));
+__uint32_t ntohl __P((__uint32_t));
+__uint16_t ntohs __P((__uint16_t));
+__END_DECLS
+#endif
+
#ifndef _BYTEORDER_FUNC_DEFINED
#define _BYTEORDER_FUNC_DEFINED
#define htonl(x) __htonl(x)
@@ -506,13 +516,6 @@ char *inet_ntoa_r __P((struct in_addr ina, char *buf)); /* in libkern */
#define ntohs(x) __ntohs(x)
#endif
-__BEGIN_DECLS
-__uint32_t htonl __P((__uint32_t));
-__uint16_t htons __P((__uint16_t));
-__uint32_t ntohl __P((__uint32_t));
-__uint16_t ntohs __P((__uint16_t));
-__END_DECLS
-
#endif /* _KERNEL */
#endif
OpenPOWER on IntegriCloud