35 lines
858 B
Text
35 lines
858 B
Text
$NetBSD: patch-ab,v 1.7 2005/02/01 16:53:58 wiz Exp $
|
|
|
|
--- dns.c.orig Thu Aug 26 00:56:53 2004
|
|
+++ dns.c Sun Jan 9 16:06:08 2005
|
|
@@ -32,9 +32,18 @@
|
|
#include <sys/socket.h>
|
|
#include <netinet/in.h>
|
|
#include <arpa/inet.h>
|
|
+
|
|
+#ifdef __APPLE__
|
|
+#include <arpa/nameser8_compat.h>
|
|
+#else
|
|
#include <arpa/nameser.h>
|
|
+#endif
|
|
#include <netdb.h>
|
|
+#ifdef __APPLE__
|
|
+#include <resolv8_compat.h>
|
|
+#else
|
|
#include <resolv.h>
|
|
+#endif
|
|
#include <unistd.h>
|
|
#include <fcntl.h>
|
|
#include <ctype.h>
|
|
@@ -814,9 +823,9 @@
|
|
{
|
|
packetheader *hp;
|
|
int r,i;
|
|
- int buf[(MaxPacketsize/sizeof (int))+1];
|
|
+ unsigned char buf[MaxPacketsize];
|
|
|
|
- r = res_mkquery(QUERY,s,C_IN,type,NULL,0,NULL,(unsigned char*)buf,MaxPacketsize);
|
|
+ r = res_mkquery(QUERY,s,C_IN,type,NULL,0,NULL,buf,MaxPacketsize);
|
|
if (r == -1) {
|
|
restell("Resolver error: Query too large.");
|
|
return;
|