sin->sin_addr.s_addr = inet_addr(host); /* See arpa/inet.h */
} else { /* Alphanumeric node name: */
-#ifdef MVS /* Oustanding problem with crsh in MVS gethostbyname */
- if(TRACE)printf("HTTCP: Calling gethostbyname(%s)\n", host);
-#endif
- phost=gethostbyname(host); /* See netdb.h */
-#ifdef MVS
- if(TRACE)printf("HTTCP: gethostbyname() returned %d\n", phost);
-#endif
+ printf("HTTCP: Calling gethostbyname2(\"%s\",AF_INET)\n", host);
+ phost=gethostbyname2(host,AF_INET); /* See netdb.h */
+ printf("HTTCP: gethostbyname() returned %d\n", phost);
+ printf("HTTCP: h_errno %d\n",h_errno);
if (!phost) {
- if (TRACE) printf(
+ printf(
"HTTPAccess: Can't find internet node name `%s'.\n",host);
return -1; /* Fail? */
}
#ifdef NEED_HOST_ADDRESS /* no -- needs name server! */
phost=gethostbyname(name); /* See netdb.h */
if (!phost) {
- if (TRACE) printf(
+ printf(
"TCP: Can't find my own internet node address for `%s'!!\n",
name);
return; /* Fail! */
#define NO (BOOLEAN)0
#endif
-#define TCP_PORT 2784 /* 80 Allocated by Jon Postel/ISI 24-Jan-92 */
+#define TCP_PORT 80 /* 80 Allocated by Jon Postel/ISI 24-Jan-92 */
/* Is character c white space? */
Arg args[1];
XtSetArg(args[0], resource, (XtArgVal) 0);
- XtGetValues(wdg, args, 1);
+/* XtGetValues(wdg, args, 1); Toni */
return args[0].value;
}