mirror of
https://github.com/php/php-src.git
synced 2024-12-13 03:44:17 +08:00
12 lines
179 B
C
12 lines
179 B
C
#include "inet.h"
|
|
|
|
int inet_aton(const char *cp, struct in_addr *inp) {
|
|
inp->s_addr = inet_addr(cp);
|
|
|
|
if (inp->s_addr == INADDR_NONE) {
|
|
return 0;
|
|
}
|
|
|
|
return 1;
|
|
}
|