From 055e1d6d343cb6a39938d6660c3fc66f242c7e7f Mon Sep 17 00:00:00 2001 From: Manuel Messner Date: Tue, 7 Feb 2017 03:14:14 +0100 Subject: payload: automatically kill dependencies for exthdr and tcpopt This patch automatically removes the dependencies for exthdr and tcpopt. # nft add rule filter input tcp option maxseg kind 3 counter. # nft list table filter input Before: # ip protocol 6 tcp option maxseg kind 3 counter After: # tcp option maxseg kind 3 counter Thus allowing to write tests as follows: # tcp option maxseg kind 3;ok Signed-off-by: Manuel Messner Signed-off-by: Florian Westphal --- include/payload.h | 2 ++ 1 file changed, 2 insertions(+) (limited to 'include/payload.h') diff --git a/include/payload.h b/include/payload.h index 5952b24f..a3d23095 100644 --- a/include/payload.h +++ b/include/payload.h @@ -42,6 +42,8 @@ extern void __payload_dependency_kill(struct payload_dep_ctx *ctx, enum proto_bases base); extern void payload_dependency_kill(struct payload_dep_ctx *ctx, struct expr *expr); +extern void exthdr_dependency_kill(struct payload_dep_ctx *ctx, + struct expr *expr); extern bool payload_can_merge(const struct expr *e1, const struct expr *e2); extern struct expr *payload_expr_join(const struct expr *e1, -- cgit v1.2.3