Added make-exim4 fixes RT#1538898
This commit is contained in:
parent
8506442f96
commit
12ffb47ea0
2 changed files with 87 additions and 0 deletions
59
helpers/DATA/exim4/t9eximevent.patch
Normal file
59
helpers/DATA/exim4/t9eximevent.patch
Normal file
|
|
@ -0,0 +1,59 @@
|
|||
--- src/transports/smtp.c.orig 2018-02-08 08:22:40.000000000 -0500
|
||||
+++ src/transports/smtp.c 2020-05-27 16:12:39.693759381 -0400
|
||||
@@ -673,12 +673,13 @@
|
||||
Arguments:
|
||||
addr the address item containing error information
|
||||
host the current host
|
||||
+ evstr the event
|
||||
|
||||
Returns: nothing
|
||||
*/
|
||||
|
||||
static void
|
||||
-deferred_event_raise(address_item *addr, host_item *host)
|
||||
+deferred_event_raise(address_item * addr, host_item * host, uschar * evstr)
|
||||
{
|
||||
uschar * action = addr->transport->event_action;
|
||||
const uschar * save_domain;
|
||||
@@ -700,7 +701,7 @@
|
||||
deliver_domain = addr->domain;
|
||||
deliver_localpart = addr->local_part;
|
||||
|
||||
-(void) event_raise(action, US"msg:host:defer",
|
||||
+(void) event_raise(action, evstr,
|
||||
addr->message
|
||||
? addr->basic_errno > 0
|
||||
? string_sprintf("%s: %s", addr->message, strerror(addr->basic_errno))
|
||||
@@ -4338,7 +4339,7 @@
|
||||
|
||||
#ifndef DISABLE_EVENT
|
||||
if (rc == DEFER)
|
||||
- deferred_event_raise(first_addr, host);
|
||||
+ deferred_event_raise(first_addr, host, US"msg:host:defer");
|
||||
#endif
|
||||
|
||||
/* If STARTTLS was accepted, but there was a failure in setting up the
|
||||
@@ -4367,10 +4368,22 @@
|
||||
write_logs(host, first_addr->message, first_addr->basic_errno);
|
||||
# ifndef DISABLE_EVENT
|
||||
if (rc == DEFER)
|
||||
- deferred_event_raise(first_addr, host);
|
||||
+ deferred_event_raise(first_addr, host, US"msg:host:defer");
|
||||
# endif
|
||||
}
|
||||
#endif /*SUPPORT_TLS*/
|
||||
+
|
||||
+#ifndef DISABLE_EVENT
|
||||
+ /* If the last host gave a defer raise a per-message event */
|
||||
+
|
||||
+ if ( !( nexthost
|
||||
+ && unexpired_hosts_tried < ob->hosts_max_try
|
||||
+ && total_hosts_tried < ob->hosts_max_try_hardlimit
|
||||
+ )
|
||||
+ && (message_defer || rc == DEFER)
|
||||
+ )
|
||||
+ deferred_event_raise(first_addr, host, US"msg:defer");
|
||||
+#endif
|
||||
}
|
||||
|
||||
/* Delivery attempt finished */
|
||||
28
helpers/make-exim4
Normal file
28
helpers/make-exim4
Normal file
|
|
@ -0,0 +1,28 @@
|
|||
#!/bin/sh
|
||||
#
|
||||
# Copyright (C) 2020 Ruben Rodriguez <ruben@trisquel.info>
|
||||
#
|
||||
# This program is free software; you can redistribute it and/or modify
|
||||
# it under the terms of the GNU General Public License as published by
|
||||
# the Free Software Foundation; either version 2 of the License, or
|
||||
# (at your option) any later version.
|
||||
#
|
||||
# This program is distributed in the hope that it will be useful,
|
||||
# but WITHOUT ANY WARRANTY; without even the implied warranty of
|
||||
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
|
||||
# GNU General Public License for more details.
|
||||
#
|
||||
# You should have received a copy of the GNU General Public License
|
||||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 USA
|
||||
#
|
||||
|
||||
VERSION=1
|
||||
|
||||
. ./config
|
||||
|
||||
patch -p0 < $DATA/t9eximevent.patch
|
||||
|
||||
changelog "Corrects event management"
|
||||
|
||||
compile
|
||||
Loading…
Add table
Add a link
Reference in a new issue