Skip to content

Commit d2c7db0

Browse files
committed
Quiet clang scan
1 parent eb5e4b0 commit d2c7db0

1 file changed

Lines changed: 5 additions & 0 deletions

File tree

src/lib/unlang/xlat_builtin.c

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -2982,6 +2982,11 @@ static xlat_action_t xlat_func_range(TALLOC_CTX *ctx, fr_dcursor_t *out,
29822982
if (step_vb && fr_type_is_null(step_vb->type)) step_vb = NULL;
29832983

29842984
if (step_vb) {
2985+
if (!end_vb) {
2986+
REDEBUG("Invalid range - 'end' cannot be null when 'step' is provided");
2987+
return XLAT_ACTION_FAIL;
2988+
}
2989+
29852990
start = fr_value_box_list_head(&start_vb->vb_group)->vb_uint64;
29862991
end = fr_value_box_list_head(&end_vb->vb_group)->vb_uint64;
29872992
step = fr_value_box_list_head(&step_vb->vb_group)->vb_uint64;

0 commit comments

Comments
 (0)