diff options
author | Florian Westphal <fw@strlen.de> | 2018-03-27 09:29:54 +0200 |
---|---|---|
committer | Florian Westphal <fw@strlen.de> | 2018-03-27 11:36:58 +0200 |
commit | 483e5ea7167e1537accf4cb083b88a8beea8f834 (patch) | |
tree | 9828b350a3b59b8d201544a720359ce2663d4827 /tests/py/any/meta.t.payload | |
parent | 65a9d639ddac244ff3abc9dfde30482ff4a4c336 (diff) |
src: avoid errouneous assert with map+concat
Phil reported following assert:
add rule ip6 f o mark set ip6 saddr . ip6 daddr . tcp dport \
map { dead::beef . f00::. 22 : 1 }
nft: netlink_linearize.c:655: netlink_gen_expr: Assertion `dreg < ctx->reg_low' failed.
This happens because "mark set" will allocate one register (the dreg),
but netlink_gen_concat_expr will populate a lot more register space if
the concat expression strings a lot of expressions together.
As the assert is useful pseudo-reserve the register space as per
concat->len and undo after generating the expressions.
Reported-by: Phil Sutter <phil@nwl.cc>
Signed-off-by: Florian Westphal <fw@strlen.de>
Diffstat (limited to 'tests/py/any/meta.t.payload')
0 files changed, 0 insertions, 0 deletions