diff --git a/core/shared/platform/common/posix/posix_socket.c b/core/shared/platform/common/posix/posix_socket.c index fb8c9ceb..d3bcf148 100644 --- a/core/shared/platform/common/posix/posix_socket.c +++ b/core/shared/platform/common/posix/posix_socket.c @@ -172,6 +172,7 @@ os_socket_inet_network(const char *cp, uint32 *out) if (!cp) return BHT_ERROR; - *out = inet_network(cp); + /* Note: ntohl(INADDR_NONE) == INADDR_NONE */ + *out = ntohl(inet_addr(cp)); return BHT_OK; -} \ No newline at end of file +}