src/sock.h
author Tero Marttila <terom@fixme.fi>
Wed, 27 May 2009 23:57:48 +0300
branchnew-lib-errors
changeset 217 7728d6ec3abf
parent 180 22967b165692
permissions -rw-r--r--
nexus.c compiles
#ifndef SOCK_H
#define SOCK_H

/**
 * @file
 *
 * Legacy sock_* interface for global state
 */
#include "error.h"
#include <sys/types.h>
#include <event2/event.h>

/**
 * Initialize the socket module's global state. Call this before calling any other sock_* functions.
 *
 * The given \a ev_base is the libevent base to use for nonblocking operation.
 *
 * @param ev_base the libevent base to use for events
 * @param err returned error info
 */
err_t sock_init (struct event_base *ev_base, error_t *err);

#endif