]> git.ipfire.org Git - thirdparty/nftables.git/commit
parser_json: Use xstrdup() when parsing rule comment
authorPhil Sutter <phil@nwl.cc>
Tue, 26 Feb 2019 21:13:40 +0000 (22:13 +0100)
committerPablo Neira Ayuso <pablo@netfilter.org>
Wed, 27 Feb 2019 10:25:14 +0000 (11:25 +0100)
commit1acebd57216e32d16ebb5684a6b2219e888997c3
tree8509a9ba0c0ed7ce6d5dec923d1c623200c24826
parentdc6a6e83b47fc7078a061350cd2b111cb2adec14
parser_json: Use xstrdup() when parsing rule comment

Use xstrdup() instead of plain strdup() for consistency (and implicit
ENOMEM checking).

Fixes: 586ad210368b7 ("libnftables: Implement JSON parser")
Signed-off-by: Phil Sutter <phil@nwl.cc>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
src/parser_json.c