[exim-cvs] namedlist_block has to be allocated mutably, to …

Page principale
Supprimer ce message
Répondre à ce message
Auteur: Exim Git Commits Mailing List
Date:  
À: exim-cvs
Sujet: [exim-cvs] namedlist_block has to be allocated mutably, to cache lookups
Gitweb: https://git.exim.org/exim.git/commitdiff/852645b30d28793d57dd46818011c7236c7a23ba
Commit:     852645b30d28793d57dd46818011c7236c7a23ba
Parent:     d56e798eb66ac044ff22f0daa2185549f5d49632
Author:     Jeremy Harris <jgh146exb@???>
AuthorDate: Thu May 13 21:31:16 2021 +0100
Committer:  Jeremy Harris <jgh146exb@???>
CommitDate: Mon Jun 28 00:30:02 2021 +0100


    namedlist_block has to be allocated mutably, to cache lookups
    paniclog from 5 - subprocess crashes
---
 src/src/readconf.c | 7 ++++++-
 1 file changed, 6 insertions(+), 1 deletion(-)


diff --git a/src/src/readconf.c b/src/src/readconf.c
index 4602dd2..0ad2061 100644
--- a/src/src/readconf.c
+++ b/src/src/readconf.c
@@ -3011,7 +3011,12 @@ read_named_list(tree_node **anchorp, int *numberp, int max, uschar *s,
BOOL forcecache = FALSE;
uschar *ss;
tree_node *t;
-namedlist_block * nb = store_get(sizeof(namedlist_block), FALSE);
+int old_pool = store_pool;
+namedlist_block * nb;
+
+store_pool = POOL_PERM;
+nb = store_get(sizeof(namedlist_block), FALSE);
+store_pool = old_pool;

if (Ustrncmp(s, "_cache", 6) == 0)
{