8#define INET_ADDRSTR_LEN INET6_ADDRSTRLEN
in_port_t inet_port(const inet_addr_t *ss)
Port in host byte order, regardless of family.
socklen_t inet_len(const inet_addr_t *ss)
Length of the concrete sockaddr in @ss, for bind()/connect()/sendto()
struct sockaddr_storage inet_addr_t
void inet_set_port(inet_addr_t *ss, in_port_t port)
Set the port (host byte order) in the correct family-specific field.
sa_family_t inet_family(const inet_addr_t *ss)
Family of @ss, AF_INET or AF_INET6.
void inet_anyaddr(sa_family_t family, in_port_t port, inet_addr_t *ss)
Initialize @ss to the wildcard address of @family with @port.
const char * inet_ntop2(const inet_addr_t *ss, char *buf, size_t len)
Presentation string of the address in @ss, e.g.