netatalk  4.6.1
Free and Open Source Apple Filing Protocol (AFP) Server
Loading...
Searching...
No Matches
test_socket_helpers.c File Reference
#include <errno.h>
#include <stdio.h>
#include <sys/select.h>
#include <sys/socket.h>
#include <unistd.h>
#include <atalk/util.h>
#include "../../libatalk/util/socket.c"

Macros

#define recv   socket_helpers_recv
#define select   socket_helpers_select
#define write   socket_helpers_write

Functions

ssize_t socket_helpers_recv (int socket, void *buffer, size_t length, int flags)
ssize_t socket_helpers_write (int fd, const void *buffer, size_t length)
int socket_helpers_select (int nfds, fd_set *readfds, fd_set *writefds, fd_set *exceptfds, struct timeval *timeout)
static void report (int passed, const char *name)
static int test_high_fd_read_fails_before_select (void)
static int test_high_fd_write_fails_before_select (void)
int main (void)

Variables

static int tests_run
static int tests_failed
static int select_calls

Macro Definition Documentation

◆ recv

#define recv   socket_helpers_recv

◆ select

#define select   socket_helpers_select

◆ write

#define write   socket_helpers_write

Function Documentation

◆ main()

int main ( void )

◆ report()

void report ( int passed,
const char * name )
static

◆ socket_helpers_recv()

ssize_t socket_helpers_recv ( int socket,
void * buffer,
size_t length,
int flags )

◆ socket_helpers_select()

int socket_helpers_select ( int nfds,
fd_set * readfds,
fd_set * writefds,
fd_set * exceptfds,
struct timeval * timeout )

◆ socket_helpers_write()

ssize_t socket_helpers_write ( int fd,
const void * buffer,
size_t length )

◆ test_high_fd_read_fails_before_select()

int test_high_fd_read_fails_before_select ( void )
static

◆ test_high_fd_write_fails_before_select()

int test_high_fd_write_fails_before_select ( void )
static

Variable Documentation

◆ select_calls

int select_calls
static

◆ tests_failed

int tests_failed
static

◆ tests_run

int tests_run
static