]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
quiet static analyzer
authorAlan T. DeKok <aland@freeradius.org>
Mon, 9 Oct 2023 19:25:20 +0000 (15:25 -0400)
committerAlan T. DeKok <aland@freeradius.org>
Mon, 9 Oct 2023 19:25:20 +0000 (15:25 -0400)
if we didn't find any match, return false

src/lib/unlang/xlat_expr.c

index 3466e20cbcc5794e91d791d2db807d0bac1a572a..6170d977ccd326e54251f2ad81bd84de65cf3fde 100644 (file)
@@ -1175,6 +1175,8 @@ static bool xlat_logical_or(xlat_logical_rctx_t *rctx, fr_value_box_list_t const
                return false;
        }
 
+       if (!found) return false;
+
        if (!rctx->box) {
                MEM(rctx->box = fr_value_box_alloc_null(rctx->ctx));
        } else {
@@ -1281,6 +1283,8 @@ static bool xlat_logical_and(xlat_logical_rctx_t *rctx, fr_value_box_list_t cons
                return false;
        }
 
+       if (!found) return false;
+
        if (!rctx->box) {
                MEM(rctx->box = fr_value_box_alloc_null(rctx));
        } else {