OpenVPN
Data Structures | Macros | Typedefs | Functions
event.h File Reference
#include "win32.h"
#include "sig.h"
#include "perf.h"
Include dependency graph for event.h:
This graph shows which files directly or indirectly include this file:

Go to the source code of this file.

Data Structures

struct  event_set_functions
 
struct  event_set_return
 
struct  event_set
 

Macros

#define EVENT_UNDEF   4
 
#define EVENT_READ   (1<<0)
 
#define EVENT_WRITE   (1<<1)
 
#define EVENT_METHOD_US_TIMEOUT   (1<<0)
 
#define EVENT_METHOD_FAST   (1<<1)
 
#define UNDEFINED_EVENT   (NULL)
 

Typedefs

typedef const struct rw_handleevent_t
 

Functions

struct event_setevent_set_init (int *maxevents, unsigned int flags)
 
static void event_free (struct event_set *es)
 
static void event_reset (struct event_set *es)
 
static void event_del (struct event_set *es, event_t event)
 
static void event_ctl (struct event_set *es, event_t event, unsigned int rwflags, void *arg)
 
static int event_wait (struct event_set *es, const struct timeval *tv, struct event_set_return *out, int outlen)
 
static void event_set_return_init (struct event_set_return *esr)
 
static void wait_signal (struct event_set *es, void *arg)
 

Macro Definition Documentation

◆ EVENT_METHOD_FAST

#define EVENT_METHOD_FAST   (1<<1)

Definition at line 42 of file event.h.

Referenced by do_event_set_init(), event_set_init(), man_connection_init(), and we_init().

◆ EVENT_METHOD_US_TIMEOUT

#define EVENT_METHOD_US_TIMEOUT   (1<<0)

Definition at line 41 of file event.h.

Referenced by do_event_set_init(), and event_set_init_simple().

◆ EVENT_READ

#define EVENT_READ   (1<<0)

◆ EVENT_UNDEF

#define EVENT_UNDEF   4

Definition at line 35 of file event.h.

◆ EVENT_WRITE

#define EVENT_WRITE   (1<<1)

◆ UNDEFINED_EVENT

#define UNDEFINED_EVENT   (NULL)

Definition at line 48 of file event.h.

Typedef Documentation

◆ event_t

typedef const struct rw_handle* event_t

Definition at line 46 of file event.h.

Function Documentation

◆ event_ctl()

static void event_ctl ( struct event_set es,
event_t  event,
unsigned int  rwflags,
void *  arg 
)
inlinestatic

◆ event_del()

static void event_del ( struct event_set es,
event_t  event 
)
inlinestatic

Definition at line 113 of file event.h.

References event_set_functions::del, and event_set::func.

Referenced by multi_tcp_delete_event(), and multi_tcp_dereference_instance().

◆ event_free()

static void event_free ( struct event_set es)
inlinestatic

Definition at line 98 of file event.h.

References event_set_functions::free, and event_set::func.

Referenced by do_close_event_set(), man_connection_close(), and multi_tcp_free().

◆ event_reset()

static void event_reset ( struct event_set es)
inlinestatic

Definition at line 107 of file event.h.

References event_set::func, and event_set_functions::reset.

Referenced by io_wait_dowork(), and man_block().

◆ event_set_init()

struct event_set* event_set_init ( int *  maxevents,
unsigned int  flags 
)

◆ event_set_return_init()

static void event_set_return_init ( struct event_set_return esr)
inlinestatic

Definition at line 135 of file event.h.

References event_set_return::arg, and event_set_return::rwflags.

◆ event_wait()

static int event_wait ( struct event_set es,
const struct timeval *  tv,
struct event_set_return out,
int  outlen 
)
inlinestatic

◆ wait_signal()

static void wait_signal ( struct event_set es,
void *  arg 
)
inlinestatic

Definition at line 144 of file event.h.

References event_ctl(), EVENT_READ, HANDLE_DEFINED, win32_signal::in, and rw_handle::read.

Referenced by io_wait_dowork(), and multi_tcp_init().