#if defined(LIBC_SCCS) && !defined(lint)
static char sccsid[] = "@(#)res_debug.c 8.1 (Berkeley) 6/4/93";
-static char rcsid[] = "$Id: res_debug.c,v 1.3 2002/02/19 20:36:12 epeyton Exp $";
+static char rcsid[] = "$Id: res_debug.c,v 1.5 2004/06/11 23:16:00 majka Exp $";
#endif /* LIBC_SCCS and not lint */
#include <sys/param.h>
#include <netinet/in.h>
#include <arpa/inet.h>
-#include <arpa/nameser.h>
+#include <arpa/nameser8_compat.h>
#include <stdio.h>
#include <netdb.h>
-#include <resolv.h>
+#include <resolv8_compat.h>
#if defined(BSD) && (BSD >= 199103)
# include <string.h>
#else
const u_char *cp, *msg;
FILE *file;
{
- int type, class, dlen, n, c;
+ int type, class, n, c;
+ int dlen;
struct in_addr inaddr;
const u_char *cp1, *cp2;
u_int32_t tmpttl, t;
putc('\n', file);
#endif
if (cp - cp1 != dlen) {
- fprintf(file, ";; packet size error (found %d, dlen was %d)\n",
- cp - cp1, dlen);
+#ifdef __LP64__
+ fprintf(file, ";; packet size error (found %ld, dlen was %d)\n", cp - cp1, dlen);
+#else
+ fprintf(file, ";; packet size error (found %d, dlen was %d)\n", cp - cp1, dlen);
+#endif
cp = NULL;
}
return (cp);