]> git.ipfire.org Git - thirdparty/nftables.git/commit
evaluate: fix crash if we add an error format rule
authorLiping Zhang <liping.zhang@spreadtrum.com>
Sat, 14 May 2016 12:43:35 +0000 (20:43 +0800)
committerFlorian Westphal <fw@strlen.de>
Sat, 14 May 2016 20:03:22 +0000 (22:03 +0200)
commitd4b86b6bfdf979a13c7cf4231bb4ec1d0c04d6a3
tree5eebb6a7a2c0400a529bf441396a10f471c473e9
parent4caf82919d3c8e85a0ebc6028229bea58a6268ba
evaluate: fix crash if we add an error format rule

If we add a such nft rule:
  nft add rule filter input ip protocol icmp tcp dport 0

we will always meet the assert condition:
  nft: evaluate.c:536: resolve_protocol_conflict: Assertion `base < (__PROTO_BASE_MAX - 1)' failed.
  Aborted (core dumped)

Signed-off-by: Florian Westphal <fw@strlen.de>
src/evaluate.c