]> git.ipfire.org Git - thirdparty/nftables.git/commit
src: Better error reporting if chain type is invalid
authorTomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
Wed, 4 Sep 2013 09:50:20 +0000 (12:50 +0300)
committerPablo Neira Ayuso <pablo@netfilter.org>
Thu, 5 Sep 2013 09:01:40 +0000 (11:01 +0200)
commitf314b4500848d90836cb3d936333bba5a0357ed7
tree287dae4aa539e31800dfa56630372a5e3a440e54
parent78c4b630124ee09dff17026b3e2cd5820942093b
src: Better error reporting if chain type is invalid

This patch verifies at command line parsing that given chain type
is valid. Possibilities are: filter, nat, and route.

nft add chain test test { type cheese hook input priority 0 };
<cmdline>:1:28-33: Error: unknown chain type cheese
add chain test test { type cheese hook input priority 0 };
                           ^^^^^^

Signed-off-by: Tomasz Bursztyka <tomasz.bursztyka@linux.intel.com>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
include/rule.h
src/parser.y
src/rule.c