libosmocore 0.3.6
Osmocom core library
src/socket.c File Reference

Osmocom socket convenience functions. More...

Functions

int osmo_sock_init (uint16_t family, uint16_t type, uint8_t proto, const char *host, uint16_t port, unsigned int flags)
 Initialize a socket (including bind/connect)
int osmo_sock_init_ofd (struct osmo_fd *ofd, int family, int type, int proto, const char *host, uint16_t port, unsigned int flags)
 Initialize a socket and fill osmo_fd.
int osmo_sock_init_sa (struct sockaddr *ss, uint16_t type, uint8_t proto, unsigned int flags)
 Initialize a socket and fill sockaddr.
static int sockaddr_equal (const struct sockaddr *a, const struct sockaddr *b, unsigned int len)
int osmo_sockaddr_is_local (struct sockaddr *addr, socklen_t addrlen)
 Determine if the given address is a local address.

Detailed Description

Osmocom socket convenience functions.