Converts between text and binary address formats.
char *inet_net_ntop int af; const char *src; void *dst; size_t size;
This function converts a network address in ascii into the binary network address. The ascii representation can be CIDR-based (for example, 18.104.22.168/24) or class-based (for example, 22.214.171.124). The argument, af, specifies the family of the address. The argument, src, points the string being passed in. The argument, dst, points to a buffer where the function will store the resulting numeric address.
If successful, 1 (one) is returned. If unsuccessful, 0 (zero) is returned if the input is not a valid IPv4 string; or a -1 (negative one) with errno set to EAFNOSUPPORT if the af argument is unknown.
The inet_net_ntop (inet_net_ntop Subroutine) subroutine, inet_ntop (inet_ntop Subroutine) subroutine, inet_pton (inet_pton Subroutine) subroutine.
Subroutines Overview in AIX 5L Version 5.1 General Programming Concepts: Writing and Debugging Programs.