From: Alan T. DeKok Date: Sun, 26 Jan 2025 21:19:14 +0000 (-0500) Subject: it helps to set enumv in the value box. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=97958bf11062aecd5fd6667902b4159588b7996e;p=thirdparty%2Ffreeradius-server.git it helps to set enumv in the value box. so that when the value is printed, it's printed as the name. This wasn't needed before, because almost all of the tmpls were unresolved data, and any printing used the tmpl name. --- diff --git a/src/lib/server/tmpl_tokenize.c b/src/lib/server/tmpl_tokenize.c index 1e9256788ab..630ec3b92f5 100644 --- a/src/lib/server/tmpl_tokenize.c +++ b/src/lib/server/tmpl_tokenize.c @@ -3159,6 +3159,7 @@ static ssize_t tmpl_afrom_enum(TALLOC_CTX *ctx, tmpl_t **out, fr_sbuff_t *in, tmpl_init(vpt, TMPL_TYPE_DATA, T_BARE_WORD, fr_sbuff_start(&our_in), fr_sbuff_used(&our_in), t_rules); (void) fr_value_box_copy(vpt, &vpt->data.literal, dv->value); + vpt->data.literal.enumv = t_rules->enumv; *out = vpt; FR_SBUFF_SET_RETURN(in, &our_in);