[exim-cvs] Avoid retry db lookups in first phase of 2-phase …

Página Inicial
Delete this message
Reply to this message
Autor: Exim Git Commits Mailing List
Data:  
Para: exim-cvs
Assunto: [exim-cvs] Avoid retry db lookups in first phase of 2-phase queue run
Gitweb: https://git.exim.org/exim.git/commitdiff/6748707c644648e9dc1c7f6249cf443aca8a0d13
Commit:     6748707c644648e9dc1c7f6249cf443aca8a0d13
Parent:     04f8907ae05b4ac5af26d4a6080b9d787c27fa7f
Author:     Jeremy Harris <jgh146exb@???>
AuthorDate: Wed Jun 19 15:29:00 2024 +0100
Committer:  Jeremy Harris <jgh146exb@???>
CommitDate: Wed Jun 19 15:29:00 2024 +0100


    Avoid retry db lookups in first phase of 2-phase queue run
---
 src/src/deliver.c | 10 +++++++---
 1 file changed, 7 insertions(+), 3 deletions(-)


diff --git a/src/src/deliver.c b/src/src/deliver.c
index 2ac56e171..d2b2c3ab2 100644
--- a/src/src/deliver.c
+++ b/src/src/deliver.c
@@ -6543,7 +6543,7 @@ opening the data file, message_subdir gets set. */
if ((deliver_datafile = spool_open_datafile(id)) < 0)
return continue_closedown(); /* yields DELIVER_NOT_ATTEMPTED */

-/* tHe value of message_size at this point has been set to the data length,
+/* The value of message_size at this point has been set to the data length,
plus one for the blank line that notionally precedes the data. */

 /* Now read the contents of the header file, which will set up the headers in
@@ -7271,9 +7271,13 @@ while (addr_new)           /* Loop until all addresses dealt with */
   address_item * addr, * parent;


/* Failure to open the retry database is treated the same as if it does
- not exist. In both cases, dbm_file is NULL. */
+ not exist. In both cases, dbm_file is NULL. For the first stage of a 2-phase
+ queue run don't bother checking domain- or address-retry info; they will take
+ effect on the second stage. */

-  if (!(dbm_file = dbfn_open(US"retry", O_RDONLY, &dbblock, FALSE, TRUE)))
+  if (f.queue_2stage)
+    dbm_file = NULL;
+  else if (!(dbm_file = dbfn_open(US"retry", O_RDONLY, &dbblock, FALSE, TRUE)))
     DEBUG(D_deliver|D_retry|D_route|D_hints_lookup)
       debug_printf("no retry data available\n");



--
## subscription configuration (requires account):
## https://lists.exim.org/mailman3/postorius/lists/exim-cvs.lists.exim.org/
## unsubscribe (doesn't require an account):
## exim-cvs-unsubscribe@???
## Exim details at http://www.exim.org/
## Please use the Wiki with this list - http://wiki.exim.org/