repo.or.cz
/
mascara-docs.git
/
blob
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
log
|
graphiclog1
|
graphiclog2
|
commit
|
commitdiff
|
tree
|
refs
|
edit
|
fork
blame
|
history
|
raw
|
HEAD
* reordered a little bit
[mascara-docs.git]
/
i86
/
elks
/
elksnet
/
ktcp
/
mylib.h
blob
f4f20652ec3586d8cd1bcb55a9fac25352cf1ae9
1
#ifndef MYLIB_H
2
#define MYLIB_H
3
4
#ifndef ntohs
5
6
#define ntohs(x) ( (((x) >> 8) & 0xff) | ((x) << 8) )
7
#define htons(x) ntohs(x)
8
#endif
9
10
#define ntohl(x) ( (((x) >> 24) & 0xff) | \
11
(((x) >> 8 ) & 0xff00) | \
12
(((x) & 0xff00) << 8) | \
13
(((x) & 0xff) << 24) )
14
15
#define htonl(x) ntohl(x)
16
17
#endif