+2004-09-21 Tom Yu <tlyu@mit.edu>
+
+ * alcocal.m4 (AC_LIBRARY_NET): Additionally, check ns_initparse,
+ since Linux prototypes it but doesn't export it.
+
2004-09-21 Tom Yu <tlyu@mit.edu>
* aclocal.m4 (KRB5_AC_NEED_BIND_8_COMPAT): Remove.
# We assume that if libresolv exists we can link against it.
# This may get us a gethostby* that doesn't respect nsswitch.
AC_CHECK_LIB(resolv, main)
-_KRB5_AC_CHECK_RES_FUNCS(res_nsearch res_search ns_name_uncompress dn_skipname)
+_KRB5_AC_CHECK_RES_FUNCS(res_nsearch res_search ns_initparse dnl
+ns_name_uncompress dn_skipname)
if test $krb5_cv_func_res_nsearch = no \
&& test $krb5_cv_func_res_search = no; then
# Attempt to link with res_search(), in case it's not prototyped.
+2004-09-21 Tom Yu <tlyu@mit.edu>
+
+ * dnsglue.c: Conditionalize some stuff on ns_initparse() instead
+ of assuming that the presence of res_nsearch() means
+ ns_initparse() is available.
+
2004-09-20 Tom Yu <tlyu@mit.edu>
* Makefile.in (STLIBOBJS, OBJS, SRCS): Add dnsglue.c.
void *ansp;
int anslen;
int ansmax;
-#if HAVE_RES_NSEARCH
+#if HAVE_NS_INITPARSE
int cur_ans;
ns_msg msg;
#else
#endif
};
-#if !HAVE_RES_NSEARCH
+#if !HAVE_NS_INITPARSE
static int initparse(struct krb5int_dns_state *);
#endif
nextincr = 2048;
maxincr = INT_MAX;
-#if HAVE_RES_NSEARCH
+#if HAVE_NS_INITPARSE
ds->cur_ans = 0;
+#endif
+
+#if HAVE_RES_NSEARCH
len = res_ninit(&statbuf);
if (len < 0)
return -1;
} while (len > ds->ansmax);
ds->anslen = len;
-#if HAVE_RES_NSEARCH
+#if HAVE_NS_INITPARSE
len = ns_initparse(ds->ansp, ds->anslen, &ds->msg);
#else
len = initparse(ds);
return 0;
}
-#if HAVE_RES_NSEARCH
+#if HAVE_NS_INITPARSE
/*
* krb5int_dns_nextans - get next matching answer record
*
/*
* Compat routines for BIND 4
*/
-#if !HAVE_RES_NSEARCH
+#if !HAVE_NS_INITPARSE
/*
* initparse