RetroArch
in.h
Go to the documentation of this file.
1 #ifndef _NETINET_IN_H
2 #define _NETINET_IN_H
3 
4 #ifdef __cplusplus
5 extern "C" {
6 #endif
7 
8 #include <stdint.h>
9 
10 struct in_addr
11 {
12  unsigned int s_addr;
13 };
14 
15 #define IPPROTO_IP 0
16 #define IPPROTO_TCP 6
17 #define IPPROTO_UDP 17
18 
19 struct sockaddr_in
20 {
21  short sin_family;
22  unsigned short sin_port;
23  struct in_addr sin_addr;
24  char sin_zero[8];
25 };
26 
27 uint32_t ntohl (uint32_t netlong);
28 uint16_t ntohs (uint16_t netshort);
29 uint32_t htonl (uint32_t hostlong);
30 uint16_t htons (uint16_t hostshort);
31 
32 #ifdef __cplusplus
33 }
34 #endif
35 
36 #endif /* _NETINET_IN_H */
unsigned short sin_port
Definition: in.h:22
uint32_t htonl(uint32_t hostlong)
Definition: network_common.c:184
Definition: ip_addr.h:64
uint16_t htons(uint16_t hostshort)
Definition: network_common.c:172
Definition: sockets.h:38
short sin_family
Definition: in.h:21
struct in_addr sin_addr
Definition: sockets.h:42
uint32_t ntohl(uint32_t netlong)
Definition: network_common.c:193
char sin_zero[8]
Definition: sockets.h:43
uint16_t ntohs(uint16_t netshort)
Definition: network_common.c:178
unsigned short uint16_t
Definition: stdint.h:125
unsigned int uint32_t
Definition: stdint.h:126
unsigned int s_addr
Definition: in.h:12