$NetBSD: patch-as,v 1.1 2014/06/15 20:48:50 jnemeth Exp $ --- sendmail/deliver.c.orig 2014-05-16 20:40:15.000000000 +0000 +++ sendmail/deliver.c @@ -28,6 +28,10 @@ SM_RCSID("@(#)$Id: deliver.c,v 8.1030 20 # include "sfsasl.h" #endif /* STARTTLS || SASL */ +#if NAMED_BIND +extern struct __res_state sm_res; +#endif + static int deliver __P((ENVELOPE *, ADDRESS *)); static void dup_queue_file __P((ENVELOPE *, ENVELOPE *, int)); static void mailfiletimeout __P((int)); @@ -1858,7 +1862,7 @@ deliver(e, firstto) #if NAMED_BIND if (ConfigLevel < 2) - _res.options &= ~(RES_DEFNAMES | RES_DNSRCH); /* XXX */ + sm_res.options &= ~(RES_DEFNAMES | RES_DNSRCH); /* XXX */ #endif /* NAMED_BIND */ if (tTd(11, 1)) @@ -3438,7 +3442,7 @@ do_transfer: } #if NAMED_BIND if (ConfigLevel < 2) - _res.options |= RES_DEFNAMES | RES_DNSRCH; /* XXX */ + sm_res.options |= RES_DEFNAMES | RES_DNSRCH; /* XXX */ #endif /* NAMED_BIND */ if (tTd(62, 1)) @@ -5710,7 +5714,7 @@ hostsignature(m, host) int hl; char *hp; char *endp; - int oldoptions = _res.options; + int oldoptions = sm_res.options; char *mxhosts[MAXMXHOSTS + 1]; unsigned short mxprefs[MAXMXHOSTS + 1]; #endif /* NAMED_BIND */ @@ -5780,7 +5784,7 @@ hostsignature(m, host) #if NAMED_BIND if (ConfigLevel < 2) - _res.options &= ~(RES_DEFNAMES | RES_DNSRCH); /* XXX */ + sm_res.options &= ~(RES_DEFNAMES | RES_DNSRCH); /* XXX */ for (hp = host; hp != NULL; hp = endp) { @@ -5908,7 +5912,7 @@ hostsignature(m, host) } makelower(s->s_hostsig.hs_sig); if (ConfigLevel < 2) - _res.options = oldoptions; + sm_res.options = oldoptions; #else /* NAMED_BIND */ /* not using BIND -- the signature is just the host name */ /*