]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
let's assert at the right point.
authorAlan T. DeKok <aland@freeradius.org>
Thu, 19 May 2022 23:27:25 +0000 (19:27 -0400)
committerAlan T. DeKok <aland@freeradius.org>
Fri, 20 May 2022 16:09:01 +0000 (12:09 -0400)
src/lib/unlang/xlat_eval.c

index 4ac3d2271a85cd1e828c105fb7ea1a22830fe00b..a063adc703b1ec6c1766cfad55e6157a1ebf54da 100644 (file)
@@ -1260,12 +1260,17 @@ xlat_action_t xlat_frame_eval(TALLOC_CTX *ctx, fr_dcursor_t *out, xlat_exp_head_
 
                                fr_value_box_copy(value, value, tmpl_value(node->vpt)); /* Also dups taint */
                                fr_dlist_insert_tail(&result, value);
-                       } else {
+                       } else if (tmpl_is_attr(node->vpt)) {
                                XLAT_DEBUG("** [%i] %s(attribute) - %%{%s}", unlang_interpret_stack_depth(request), __FUNCTION__,
                                           node->fmt);
                                xlat_debug_log_expansion(request, node, NULL);
 
                                if (xlat_eval_pair_real(ctx, &result, request, node->vpt) == XLAT_ACTION_FAIL) goto fail;
+                       } else {
+                               /*
+                                *      @todo - write code here!
+                                */
+                               fr_assert(0);
                        }
 
                        xlat_debug_log_list_result(request, &result);