Copyright (C) 2000-2012 |
Manpages inet_ntopSection: Linux Programmer's Manual (3 )Updated: 2000-12-18 Index Return to Main Contents NAMEinet_ntop - Parse network address structuresSYNOPSIS#include <sys/types.h> #include <sys/socket.h> #include <arpa/inet.h> const char *inet_ntop(int af, const void *src, char *dst, size_t cnt); DESCRIPTIONThis function converts the network address structure src in the af address family into a character string, which is copied to a character buffer dst, which is cnt bytes long.inet_ntop(3) extends the inet_ntoa(3) function to support multiple address families, inet_ntoa(3) is now considered to be deprecated in favor of inet_ntop(3). The following address families are currently supported:
RETURN VALUEinet_ntop returns a non-null pointer to dst. NULL is returned if there was an error, with errno set to EAFNOSUPPORT if af was not set to a valid address family, or to ENOSPC if the converted address string would exceed the size of dst given by the cnt argument.SEE ALSOinet_pton(3)BUGSAF_INET6 converts IPv6-mapped IPv4 addresses into an IPv6 format.
IndexThis document was created by man2html, using the manual pages. Time: 13:55:51 GMT, April 26, 2024 |