repo.or.cz
/
minix3.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
output CRLF instead of just LF to serial
[minix3.git]
/
lib
/
ip
/
hton.c
blob
4f93f591ac42c56955d9ed3f86dcf3ee4ccfe4a7
1
/*
2
hton.c
3
*/
4
5
#include <sys/types.h>
6
#include <minix/config.h>
7
#include <net/hton.h>
8
9
u16_t _tmp
;
10
u32_t _tmp_l
;
11
12
#if _WORD_SIZE > 2
13
u16_t
(
htons
)(
u16_t x
) {
return
HTONS
(
x
); }
14
u16_t
(
ntohs
)(
u16_t x
) {
return
NTOHS
(
x
); }
15
u32_t
(
htonl
)(
u32_t x
) {
return
HTONL
(
x
); }
16
u32_t
(
ntohl
)(
u32_t x
) {
return
NTOHL
(
x
); }
17
#endif
18