diff options
Diffstat (limited to 'src/callout.c')
-rw-r--r-- | src/callout.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/src/callout.c b/src/callout.c index 633a33b7..1d46bc70 100644 --- a/src/callout.c +++ b/src/callout.c @@ -634,10 +634,10 @@ mf_status callout_mx(struct smtp_io_data *iop, const char *hostname, int *pcount) { int i; - struct mxbuf mxbuf; + struct dns_reply reply; mf_status rc, mxstat; - mxstat = getmx(hostname, &mxbuf); + mxstat = getmx(hostname, &reply); if (pcount) *pcount = 0; @@ -646,20 +646,20 @@ callout_mx(struct smtp_io_data *iop, const char *hostname, int *pcount) mu_debug(MF_SOURCE_CALLOUT, MU_DEBUG_TRACE1, ("Checking MX servers for %s", iop->email)); rc = mf_not_found; - for (i = 0; i < mxbuf.mx_cnt; i++) { - rc = callout_host(iop, mxbuf.mx_buf[i]); + for (i = 0; i < reply.count; i++) { + rc = callout_host(iop, reply.data.str[i]); if (mf_resolved(rc)) break; } if (pcount) - *pcount = mxbuf.mx_cnt; + *pcount = reply.count; + dns_reply_free(&reply); break; default: rc = mxstat; break; } - mxbuf_free(&mxbuf); return rc; } |