From: Nick Porter Date: Thu, 26 Jan 2023 11:57:31 +0000 (+0000) Subject: Logic corrections X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=352735e4b84f69a4d20fcfcce27e92d9d92f4350;p=thirdparty%2Ffreeradius-server.git Logic corrections --- diff --git a/src/lib/server/cond_tokenize.c b/src/lib/server/cond_tokenize.c index 0e3108d277b..cb8dba41502 100644 --- a/src/lib/server/cond_tokenize.c +++ b/src/lib/server/cond_tokenize.c @@ -881,7 +881,7 @@ static CC_HINT(nonnull) int cond_forbid_groups(tmpl_t *vpt, fr_sbuff_t *in, fr_s { if (!tmpl_is_attr(vpt) || tmpl_attr_tail_is_unresolved(vpt)) return 0; - if (tmpl_is_list(vpt) || tmpl_attr_is_list_attr(tmpl_attr_tail(vpt))) { + if (tmpl_is_list(vpt)) { fr_strerror_const("Cannot use list references in condition"); fr_sbuff_set(in, m_lhs); return -1; diff --git a/src/lib/unlang/compile.c b/src/lib/unlang/compile.c index 9968d1fc9be..c029e2edf59 100644 --- a/src/lib/unlang/compile.c +++ b/src/lib/unlang/compile.c @@ -897,7 +897,7 @@ int unlang_fixup_update(map_t *map, void *ctx) /* * What exactly where you expecting to happen here? */ - if (tmpl_is_attr(map->lhs) && + if (tmpl_attr_tail_da_is_leaf(map->lhs) && tmpl_is_list(map->rhs)) { cf_log_err(map->ci, "Can't copy list into an attribute"); return -1;