diff options
author | Pablo Neira Ayuso <pablo@netfilter.org> | 2023-08-30 13:08:17 +0200 |
---|---|---|
committer | Pablo Neira Ayuso <pablo@netfilter.org> | 2023-08-31 16:38:11 +0200 |
commit | 1fd8524ffd991d949ff77a9fd5e1b088cb942ed1 (patch) | |
tree | eb9bb58718eae8aceb00e3415b808ea412171b37 /src/parser_json.c | |
parent | b3c1d9faef50191a5a445cbb16256b147d30c9d8 (diff) |
src: use internal_location for unspecified location at allocation time
Set location to internal_location instead of NULL to ensure this is
always set.
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'src/parser_json.c')
-rw-r--r-- | src/parser_json.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/src/parser_json.c b/src/parser_json.c index 4ea5b432..01d42283 100644 --- a/src/parser_json.c +++ b/src/parser_json.c @@ -3175,7 +3175,7 @@ static struct cmd *json_parse_cmd_add_set(struct json_ctx *ctx, json_t *root, break; } - set = set_alloc(NULL); + set = set_alloc(&internal_location); if (json_unpack(root, "{s:o}", "type", &tmp)) { json_error(ctx, "Invalid set type."); |