BSHA3  0.17.99
P2P Blockchain, based on Bitcoin
Macros | Typedefs | Functions
compat.h File Reference
#include <type_traits>
#include <fcntl.h>
#include <sys/mman.h>
#include <sys/select.h>
#include <sys/socket.h>
#include <sys/types.h>
#include <net/if.h>
#include <netinet/in.h>
#include <netinet/tcp.h>
#include <arpa/inet.h>
#include <ifaddrs.h>
#include <limits.h>
#include <netdb.h>
#include <unistd.h>
#include <errno.h>
Include dependency graph for compat.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Macros

#define IS_TRIVIALLY_CONSTRUCTIBLE   std::is_trivially_default_constructible
 
#define WSAGetLastError()   errno
 
#define WSAEINVAL   EINVAL
 
#define WSAEALREADY   EALREADY
 
#define WSAEWOULDBLOCK   EWOULDBLOCK
 
#define WSAEMSGSIZE   EMSGSIZE
 
#define WSAEINTR   EINTR
 
#define WSAEINPROGRESS   EINPROGRESS
 
#define WSAEADDRINUSE   EADDRINUSE
 
#define WSAENOTSOCK   EBADF
 
#define INVALID_SOCKET   (SOCKET)(~0)
 
#define SOCKET_ERROR   -1
 
#define PRIO_MAX   20
 
#define THREAD_PRIORITY_LOWEST   PRIO_MAX
 
#define THREAD_PRIORITY_BELOW_NORMAL   2
 
#define THREAD_PRIORITY_LOWEST   PRIO_MAX
 
#define THREAD_PRIORITY_BELOW_NORMAL   2
 
#define THREAD_PRIORITY_NORMAL   0
 
#define THREAD_PRIORITY_ABOVE_NORMAL   (-2)
 
#define MAX_PATH   1024
 

Typedefs

typedef unsigned int SOCKET
 
typedef void * sockopt_arg_type
 

Functions

size_t strnlen (const char *start, size_t max_len)
 

Macro Definition Documentation

◆ INVALID_SOCKET

#define INVALID_SOCKET   (SOCKET)(~0)

Definition at line 73 of file compat.h.

◆ IS_TRIVIALLY_CONSTRUCTIBLE

#define IS_TRIVIALLY_CONSTRUCTIBLE   std::is_trivially_default_constructible

Definition at line 20 of file compat.h.

◆ MAX_PATH

#define MAX_PATH   1024

Definition at line 93 of file compat.h.

◆ PRIO_MAX

#define PRIO_MAX   20

Definition at line 78 of file compat.h.

◆ SOCKET_ERROR

#define SOCKET_ERROR   -1

Definition at line 74 of file compat.h.

◆ THREAD_PRIORITY_ABOVE_NORMAL

#define THREAD_PRIORITY_ABOVE_NORMAL   (-2)

Definition at line 85 of file compat.h.

◆ THREAD_PRIORITY_BELOW_NORMAL [1/2]

#define THREAD_PRIORITY_BELOW_NORMAL   2

Definition at line 83 of file compat.h.

◆ THREAD_PRIORITY_BELOW_NORMAL [2/2]

#define THREAD_PRIORITY_BELOW_NORMAL   2

Definition at line 83 of file compat.h.

◆ THREAD_PRIORITY_LOWEST [1/2]

#define THREAD_PRIORITY_LOWEST   PRIO_MAX

Definition at line 82 of file compat.h.

◆ THREAD_PRIORITY_LOWEST [2/2]

#define THREAD_PRIORITY_LOWEST   PRIO_MAX

Definition at line 82 of file compat.h.

◆ THREAD_PRIORITY_NORMAL

#define THREAD_PRIORITY_NORMAL   0

Definition at line 84 of file compat.h.

◆ WSAEADDRINUSE

#define WSAEADDRINUSE   EADDRINUSE

Definition at line 71 of file compat.h.

◆ WSAEALREADY

#define WSAEALREADY   EALREADY

Definition at line 66 of file compat.h.

◆ WSAEINPROGRESS

#define WSAEINPROGRESS   EINPROGRESS

Definition at line 70 of file compat.h.

◆ WSAEINTR

#define WSAEINTR   EINTR

Definition at line 69 of file compat.h.

◆ WSAEINVAL

#define WSAEINVAL   EINVAL

Definition at line 65 of file compat.h.

◆ WSAEMSGSIZE

#define WSAEMSGSIZE   EMSGSIZE

Definition at line 68 of file compat.h.

◆ WSAENOTSOCK

#define WSAENOTSOCK   EBADF

Definition at line 72 of file compat.h.

◆ WSAEWOULDBLOCK

#define WSAEWOULDBLOCK   EWOULDBLOCK

Definition at line 67 of file compat.h.

◆ WSAGetLastError

#define WSAGetLastError ( )    errno

Definition at line 64 of file compat.h.

Typedef Documentation

◆ SOCKET

typedef unsigned int SOCKET

Definition at line 62 of file compat.h.

◆ sockopt_arg_type

typedef void* sockopt_arg_type

Definition at line 110 of file compat.h.

Function Documentation

◆ strnlen()

size_t strnlen ( const char *  start,
size_t  max_len 
)

Definition at line 12 of file strnlen.cpp.

Here is the caller graph for this function: