#include <fcntl.h>
#include <sys/stat.h>
+// This is defined here since arpa\inet.h defines this array as an extern,
+// and arpa\inet.h gets included by the inet_ntoa call.
+char nwinet_scratch[18] = {'\0'};
+
+
u_long
nw_htonl(u_long hostlong)
{
void
nw_sethostent(int stayopen)
{
+#ifdef HAS_SETHOSTENT
sethostent(stayopen);
+#endif
}
void
nw_setnetent(int stayopen)
{
+#ifdef HAS_SETNETENT
setnetent(stayopen);
+#endif
}
void
nw_setprotoent(int stayopen)
{
+#ifdef HAS_SETPROTENT
setprotoent(stayopen);
+#endif
}
void
nw_setservent(int stayopen)
{
+#ifdef HAS_SETSERVENT
setservent(stayopen);
+#endif
}
int
return inet_addr((char*)cp);
}
+char *
+nw_inet_ntoa(struct in_addr in)
+{
+ return inet_ntoa(in);
+}
+
SOCKET
nw_socket(int af, int type, int protocol)
{