+2004-11-19 Ken Raeburn <raeburn@mit.edu>
+
+ * fake-addrinfo.c (HAVE_GETADDRINFO, HAVE_GETNAMEINFO)[_WIN32]:
+ Don't define here.
+ (protoname): Handle IPPROTO_IGMP.
+ (debug_dump_addrinfo_args): Update for current interfaces to
+ socktypename and familyname.
+
2004-11-15 Ken Raeburn <raeburn@mit.edu>
* cache-addrinfo.h, init-addrinfo.c: New files, split out from
# include <stdlib.h> /* strtoul */
#endif
-#ifdef _WIN32
-#define HAVE_GETADDRINFO 1
-#define HAVE_GETNAMEINFO 1
-#endif
-
/* Do we actually have *any* systems we care about that don't provide
either getaddrinfo or one of these two flavors of
#ifdef IPPROTO_COMP
X(COMP);
#endif
+#ifdef IPPROTO_IGMP
+ X(IGMP);
+#endif
sprintf(buf, " %-2d", p);
return buf;
static void debug_dump_addrinfos (const struct addrinfo *ai)
{
int count = 0;
+ char buf[10];
fprintf(stderr, "addrinfos returned:\n");
while (ai) {
fprintf(stderr, "%p...", ai);
- fprintf(stderr, " socktype=%s", socktypename(ai->ai_socktype));
- fprintf(stderr, " ai_family=%s", familyname(ai->ai_family));
+ fprintf(stderr, " socktype=%s", socktypename(ai->ai_socktype, buf));
+ fprintf(stderr, " ai_family=%s", familyname(ai->ai_family, buf));
if (ai->ai_family != ai->ai_addr->sa_family)
fprintf(stderr, " sa_family=%s",
- familyname(ai->ai_addr->sa_family));
+ familyname(ai->ai_addr->sa_family, buf));
fprintf(stderr, "\n");
ai = ai->ai_next;
count++;