php-internal-docs 8.4.8
Unofficial docs for php/php-src
Loading...
Searching...
No Matches
sendrecvmsg.c File Reference
#include <php.h>
#include "php_sockets.h"
#include "sendrecvmsg.h"
#include "conversions.h"
#include <limits.h>
#include <Zend/zend_llist.h>

Go to the source code of this file.

Macros

#define MAX_USER_BUFF_SIZE   ((size_t)(100*1024*1024))
 
#define DEFAULT_BUFF_SIZE   8192
 
#define MAX_ARRAY_KEY_SIZE   128
 
#define LONG_CHECK_VALID_INT(l, arg_pos)
 
#define PUT_ENTRY(sizev, var_size, calc, from, to, level, type)
 

Functions

ancillary_reg_entryget_ancillary_reg_entry (int cmsg_level, int msg_type)
 
 PHP_FUNCTION (socket_sendmsg)
 
 PHP_FUNCTION (socket_recvmsg)
 
 PHP_FUNCTION (socket_cmsg_space)
 
void php_socket_sendrecvmsg_init (INIT_FUNC_ARGS)
 
void php_socket_sendrecvmsg_shutdown (SHUTDOWN_FUNC_ARGS)
 

Macro Definition Documentation

◆ DEFAULT_BUFF_SIZE

#define DEFAULT_BUFF_SIZE   8192

Definition at line 32 of file sendrecvmsg.c.

◆ LONG_CHECK_VALID_INT

#define LONG_CHECK_VALID_INT ( l,
arg_pos )
Value:
do { \
if ((l) < INT_MIN || (l) > INT_MAX) { \
zend_argument_value_error((arg_pos), "must be between %d and %d", INT_MIN, INT_MAX); \
RETURN_THROWS(); \
} \
} while (0)
#define INT_MIN
Definition php.h:241
#define INT_MAX
Definition php.h:237

Definition at line 71 of file sendrecvmsg.c.

◆ MAX_ARRAY_KEY_SIZE

#define MAX_ARRAY_KEY_SIZE   128

Definition at line 33 of file sendrecvmsg.c.

◆ MAX_USER_BUFF_SIZE

#define MAX_USER_BUFF_SIZE   ((size_t)(100*1024*1024))

Definition at line 31 of file sendrecvmsg.c.

◆ PUT_ENTRY

#define PUT_ENTRY ( sizev,
var_size,
calc,
from,
to,
level,
type )
Value:
entry.size = sizev; \
entry.var_el_size = var_size; \
entry.calc_space = calc; \
entry.from_array = from; \
entry.to_array = to; \
key.cmsg_level = level; \
key.cmsg_type = type; \
zend_hash_str_update_mem(&ancillary_registry.ht, (char*)&key, sizeof(key), (void*)&entry, sizeof(entry))
zend_ffi_type * type
Definition ffi.c:3812
unsigned char key[REFLECTION_KEY_LEN]

Function Documentation

◆ get_ancillary_reg_entry()

ancillary_reg_entry * get_ancillary_reg_entry ( int cmsg_level,
int msg_type )

Definition at line 156 of file sendrecvmsg.c.

◆ PHP_FUNCTION() [1/3]

PHP_FUNCTION ( socket_cmsg_space )

Definition at line 284 of file sendrecvmsg.c.

◆ PHP_FUNCTION() [2/3]

PHP_FUNCTION ( socket_recvmsg )

Definition at line 219 of file sendrecvmsg.c.

◆ PHP_FUNCTION() [3/3]

PHP_FUNCTION ( socket_sendmsg )

Definition at line 178 of file sendrecvmsg.c.

◆ php_socket_sendrecvmsg_init()

void php_socket_sendrecvmsg_init ( INIT_FUNC_ARGS )

Definition at line 423 of file sendrecvmsg.c.

◆ php_socket_sendrecvmsg_shutdown()

void php_socket_sendrecvmsg_shutdown ( SHUTDOWN_FUNC_ARGS )

Definition at line 430 of file sendrecvmsg.c.

Variable Documentation

◆ ht

Definition at line 81 of file sendrecvmsg.c.

◆ initialized

int initialized

Definition at line 80 of file sendrecvmsg.c.