LibC: Fix netinet/in.h and arpa/inet.h definitions
This commit is contained in:
28
userspace/libraries/LibC/include/bits/inet_common.h
Normal file
28
userspace/libraries/LibC/include/bits/inet_common.h
Normal file
@@ -0,0 +1,28 @@
|
||||
#ifndef _BITS_INET_COMMON_H
|
||||
#define _BITS_INET_COMMON_H 1
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
|
||||
__BEGIN_DECLS
|
||||
|
||||
#include <inttypes.h>
|
||||
|
||||
#define INET_ADDRSTRLEN 16
|
||||
#define INET6_ADDRSTRLEN 46
|
||||
|
||||
typedef uint16_t in_port_t;
|
||||
typedef uint32_t in_addr_t;
|
||||
|
||||
struct in_addr
|
||||
{
|
||||
in_addr_t s_addr;
|
||||
};
|
||||
|
||||
uint32_t htonl(uint32_t);
|
||||
uint16_t htons(uint16_t);
|
||||
uint32_t ntohl(uint32_t);
|
||||
uint16_t ntohs(uint16_t);
|
||||
|
||||
__END_DECLS
|
||||
|
||||
#endif
|
||||
12
userspace/libraries/LibC/include/bits/types/socklen_t.h
Normal file
12
userspace/libraries/LibC/include/bits/types/socklen_t.h
Normal file
@@ -0,0 +1,12 @@
|
||||
#ifndef _BITS_TYPES_SOCKLEN_T_H
|
||||
#define _BITS_TYPES_SOCKLEN_T_H 1
|
||||
|
||||
#include <sys/cdefs.h>
|
||||
|
||||
__BEGIN_DECLS
|
||||
|
||||
typedef long socklen_t;
|
||||
|
||||
__END_DECLS
|
||||
|
||||
#endif
|
||||
Reference in New Issue
Block a user