is_valid_IP — Determines whether or not
string is a valid IP address
int **is_valid_IP** ( | string, | |
| | family, | |
| | address
); | |
Determines whether or not
string is a valid IP address.
The string to be validated.
As a side effect, this address will be populated with one of the following values:
The following typedef applies to the
typedef uint8_t u_int8_t;
An address of the system struct
struct in6_addr. As a side effect, this address will be populated with either
struct in6_addr (AF_INET6)data or
struct in_addr (AF_INET)data. If
AF_INET, then the caller should cast the value of
struct in_addrin order to access the data structure for an IPv4 address.
This is a Boolean function that returns
string is valid IP address and
0 otherwise. If the string validates, then
address will have
struct in6_addr data.
It is legal to call this function in any thread.