From 56dcebba700abf332586a428cd436460ed44e873 Mon Sep 17 00:00:00 2001 From: Eric Faurot Date: Wed, 6 Jun 2018 19:12:10 +0000 Subject: code cleanup ok gilles@ semarie@ --- usr.sbin/smtpd/mta.c | 9 +++++---- 1 file changed, 5 insertions(+), 4 deletions(-) (limited to 'usr.sbin') diff --git a/usr.sbin/smtpd/mta.c b/usr.sbin/smtpd/mta.c index 0791e33f3d9..b587fb1a24e 100644 --- a/usr.sbin/smtpd/mta.c +++ b/usr.sbin/smtpd/mta.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mta.c,v 1.216 2018/06/06 12:00:26 eric Exp $ */ +/* $OpenBSD: mta.c,v 1.217 2018/06/06 19:12:09 eric Exp $ */ /* * Copyright (c) 2008 Pierre-Yves Ritschard @@ -660,9 +660,6 @@ mta_handle_envelope(struct envelope *evp, const char *smarthost) return; } - if (smarthost && dispatcher->u.remote.tls_noverify == 0) - relayh.flags |= F_TLS_VERIFY; - relay = mta_relay(evp, &relayh); /* ignore if we don't know the limits yet */ if (relay->limits && @@ -1744,6 +1741,10 @@ mta_relay(struct envelope *e, struct relayhost *relayh) if (!key.authlabel[0]) key.authlabel = NULL; + if (dispatcher->u.remote.smarthost && + dispatcher->u.remote.tls_noverify == 0) + key.flags |= F_TLS_VERIFY; + if ((r = SPLAY_FIND(mta_relay_tree, &relays, &key)) == NULL) { r = xcalloc(1, sizeof *r); TAILQ_INIT(&r->tasks); -- cgit v1.2.3