inet_ntop(3) Library Functions Manual inet_ntop(3) inet_ntop - IPv4 IPv6 (libc -lc) #include const char *inet_ntop(socklen_t size; int af, const void *restrict src, char dst[restrict size], socklen_t size); src af . dst . size. inet_ntop() inet_ntoa(3) inet_ntoa(3) inet_ntop(). : AF_INET src struct in_addr ( ) IPv4 "ddd.ddd.ddd.ddd". dst INET_ADDRSTRLEN . AF_INET6 src struct in6_addr ( ) IPv6 . dst INET6_ADDRSTRLEN . inet_ntop() dst. NULL errno . EAFNOSUPPORT af . ENOSPC size. attributes(7). +----------------------+------------------------------------+---------------------------------------------------------------------------------------------+ | | | | +----------------------+------------------------------------+---------------------------------------------------------------------------------------------+ |inet_ntop() | | (locale) (MT-Safe) | +----------------------+------------------------------------+---------------------------------------------------------------------------------------------+ POSIX.1-2008. POSIX.1-2001. RFC 2553 size size_t. RFC 2553. glibc 2.0 2.1 size_t 2.2 socklen_t. AF_INET6 IPv6 IPv4 IPv6. inet_pton(3). getnameinfo(3), inet(3), inet_pton(3) 3 . . : . 6.18 28 2025 inet_ntop(3)