Luanti 5.10.0-dev
 
Loading...
Searching...
No Matches
socket.cpp File Reference
#include "socket.h"
#include <cstdio>
#include <iostream>
#include <cstdlib>
#include <cstring>
#include <iomanip>
#include "util/string.h"
#include "util/numeric.h"
#include "constants.h"
#include "debug.h"
#include "log.h"
#include <cerrno>
#include <sys/types.h>
#include <sys/socket.h>
#include <netinet/in.h>
#include <fcntl.h>
#include <poll.h>
#include <unistd.h>
#include <arpa/inet.h>
+ Include dependency graph for socket.cpp:

Macros

#define LAST_SOCKET_ERR()   (errno)
 
#define SOCKET_ERR_STR(e)   strerror(e)
 

Functions

void sockets_init ()
 
void sockets_cleanup ()
 

Variables

static bool g_sockets_initialized = false
 

Macro Definition Documentation

◆ LAST_SOCKET_ERR

#define LAST_SOCKET_ERR ( )    (errno)

◆ SOCKET_ERR_STR

#define SOCKET_ERR_STR ( e)    strerror(e)

Function Documentation

◆ sockets_cleanup()

void sockets_cleanup ( )

References g_sockets_initialized.

Referenced by uninit_common().

+ Here is the caller graph for this function:

◆ sockets_init()

void sockets_init ( )

References g_sockets_initialized.

Referenced by init_common().

+ Here is the caller graph for this function:

Variable Documentation

◆ g_sockets_initialized

bool g_sockets_initialized = false
static