Defines | Functions

getaddrinfo.c File Reference

Include dependency graph for getaddrinfo.c:

Defines

#define AF_UNSPEC   0

Functions

int vlc_getnameinfo (const struct sockaddr *sa, int salen, char *host, int hostlen, int *portnum, int flags)
int vlc_getaddrinfo (vlc_object_t *p_this, const char *node, int i_port, const struct addrinfo *p_hints, struct addrinfo **res)
 Resolves a host name to a list of socket addresses (like getaddrinfo()).

Define Documentation

#define AF_UNSPEC   0

Function Documentation

int vlc_getaddrinfo ( vlc_object_t p_this,
const char *  node,
int  i_port,
const struct addrinfo *  p_hints,
struct addrinfo **  res 
)

Resolves a host name to a list of socket addresses (like getaddrinfo()).

Parameters:
p_this a VLC object
node host name to resolve (encoded as UTF-8), or NULL
i_port port number for the socket addresses
p_hints parameters (see getaddrinfo() manual page)
res pointer set to the resulting chained list.
Returns:
0 on success, a getaddrinfo() error otherwise. On failure, *res is undefined. On success, it must be freed with freeaddrinfo().

References AI_NUMERICSERV, EAI_BADFLAGS, getaddrinfo(), and msg_Err.

Referenced by net_Connect(), net_ConnectDgram(), net_Listen(), net_ListenSingle(), net_OpenDgram(), SocksHandshakeTCP(), and sout_AnnounceRegisterSDP().

int vlc_getnameinfo ( const struct sockaddr *  sa,
int  salen,
char *  host,
int  hostlen,
int *  portnum,
int  flags 
)
 All Data Structures Files Functions Variables Typedefs Enumerations Enumerator Defines