/*
* client.c -- connect to a server
*
- * $Id$
- *
* This code is Copyright (c) 2002, by the authors of nmh. See the
* COPYRIGHT file in the root directory of the nmh distribution for
* complete copyright information.
}
memset(&hints, 0, sizeof(hints));
+#ifdef AI_ADDRCONFIG
hints.ai_flags = AI_ADDRCONFIG;
+#endif
hints.ai_family = PF_UNSPEC;
hints.ai_socktype = SOCK_STREAM;
char address[NI_MAXHOST];
rc = getnameinfo(ai->ai_addr, ai->ai_addrlen, address,
- sizeof(address), NULL, NULL, NI_NUMERICHOST);
+ sizeof(address), NULL, 0, NI_NUMERICHOST);
fprintf(stderr, "Connecting to %s...\n",
rc ? "unknown" : address);