diff options
| author | Pablo Neira Ayuso <pablo@netfilter.org> | 2025-08-13 15:15:08 +0200 |
|---|---|---|
| committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2025-08-27 23:52:08 +0200 |
| commit | e8c7a780d2755f5cccd7369f32f771bab2fcaf63 (patch) | |
| tree | d5a6734b4b196c667eaa5dcdd7713aaa2b0af5cc /src/parser_json.c | |
| parent | 15479e66d20dda2ddd670159c5ef005320f2398c (diff) | |
src: replace compound_expr_add() by type safe list_expr_add()
Replace compound_expr_add() by list_expr_add() to validate type.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'src/parser_json.c')
| -rw-r--r-- | src/parser_json.c | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/src/parser_json.c b/src/parser_json.c index 6ed1841c..c107dfc8 100644 --- a/src/parser_json.c +++ b/src/parser_json.c @@ -1704,7 +1704,7 @@ static struct expr *json_parse_expr(struct json_ctx *ctx, json_t *root) expr_free(list); return NULL; } - compound_expr_add(list, expr); + list_expr_add(list, expr); } return list; case JSON_TRUE: @@ -3038,7 +3038,7 @@ static struct expr *json_parse_devs(struct json_ctx *ctx, json_t *root) return NULL; } - compound_expr_add(expr, tmp); + list_expr_add(expr, tmp); return expr; } if (!json_is_array(root)) { @@ -3059,7 +3059,7 @@ static struct expr *json_parse_devs(struct json_ctx *ctx, json_t *root) expr_free(expr); return NULL; } - compound_expr_add(expr, tmp); + list_expr_add(expr, tmp); } return expr; } |
