summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--src/parser_json.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/parser_json.c b/src/parser_json.c
index 79715536..9b7aef4b 100644
--- a/src/parser_json.c
+++ b/src/parser_json.c
@@ -2711,8 +2711,9 @@ static struct cmd *json_parse_cmd_replace(struct json_ctx *ctx,
struct rule *rule;
size_t index;
- if (json_unpack_err(ctx, root, "{s:o}", "rule", &rule))
+ if (json_unpack_err(ctx, root, "{s:o}", "rule", &tmp))
return NULL;
+ root = tmp;
if (json_unpack_err(ctx, root, "{s:s, s:s, s:s, s:o}",
"family", &family,