]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
return correct error
authorAlan T. DeKok <aland@freeradius.org>
Wed, 17 Nov 2021 19:48:46 +0000 (14:48 -0500)
committerAlan T. DeKok <aland@freeradius.org>
Wed, 17 Nov 2021 19:48:46 +0000 (14:48 -0500)
src/bin/unit_test_attribute.c

index 354b927549ef7ae26cbd704cd1727e2d6a40d758..3c57626b3144dcd6dffb6eccb25642abebf64927 100644 (file)
@@ -1235,7 +1235,9 @@ static size_t command_calc(command_result_t *result, command_file_ctx_t *cc,
                fr_value_box_init(out, type, NULL, false);
        }
 
-       if (fr_value_calc(cc->tmp_ctx, out, type, a, op, b) < 0) RETURN_PARSE_ERROR(0);
+       if (fr_value_calc(cc->tmp_ctx, out, type, a, op, b) < 0) {
+               RETURN_OK_WITH_ERROR();
+       }
 
        slen = fr_value_box_print(&FR_SBUFF_OUT(data, COMMAND_OUTPUT_MAX), out, NULL);
        if (slen <= 0) RETURN_OK_WITH_ERROR();