From: Alan T. DeKok Date: Mon, 23 May 2022 20:27:26 +0000 (-0400) Subject: set more flags correctly X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ff4f8ad2b41bd5a27835bea4e242fbfb34f95a31;p=thirdparty%2Ffreeradius-server.git set more flags correctly --- diff --git a/src/lib/unlang/xlat_tokenize.c b/src/lib/unlang/xlat_tokenize.c index c7442b86914..8d8082f0d31 100644 --- a/src/lib/unlang/xlat_tokenize.c +++ b/src/lib/unlang/xlat_tokenize.c @@ -379,6 +379,13 @@ static inline int xlat_tokenize_function_mono(xlat_exp_head_t *head, } xlat_flags_merge(&node->flags, &node->call.args->flags); + + if (!func) { + node->flags.can_purify = node->call.args->flags.can_purify; + } else { + node->flags.can_purify = (node->call.func->flags.pure && node->call.args->flags.pure) | node->call.args->flags.can_purify; + } + xlat_exp_insert_tail(head, node); return 0;