summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
-rw-r--r--include/netlink.h1
-rw-r--r--src/netlink.c5
-rw-r--r--src/rule.c3
3 files changed, 1 insertions, 8 deletions
diff --git a/include/netlink.h b/include/netlink.h
index e27d75ea..b7e2232f 100644
--- a/include/netlink.h
+++ b/include/netlink.h
@@ -108,7 +108,6 @@ extern struct rule *netlink_delinearize_rule(struct netlink_ctx *ctx,
struct nftnl_rule *r);
extern int netlink_list_chains(struct netlink_ctx *ctx, const struct handle *h);
-extern int netlink_flush_chain(struct netlink_ctx *ctx, const struct cmd *cmd);
extern struct chain *netlink_delinearize_chain(struct netlink_ctx *ctx,
const struct nftnl_chain *nlc);
diff --git a/src/netlink.c b/src/netlink.c
index 60635054..b7638815 100644
--- a/src/netlink.c
+++ b/src/netlink.c
@@ -535,11 +535,6 @@ int netlink_list_chains(struct netlink_ctx *ctx, const struct handle *h)
return 0;
}
-int netlink_flush_chain(struct netlink_ctx *ctx, const struct cmd *cmd)
-{
- return mnl_nft_rule_del(ctx, cmd);
-}
-
struct table *netlink_delinearize_table(struct netlink_ctx *ctx,
const struct nftnl_table *nlt)
{
diff --git a/src/rule.c b/src/rule.c
index 34ce7693..14a61a04 100644
--- a/src/rule.c
+++ b/src/rule.c
@@ -2259,9 +2259,8 @@ static int do_command_flush(struct netlink_ctx *ctx, struct cmd *cmd)
{
switch (cmd->obj) {
case CMD_OBJ_TABLE:
- return mnl_nft_rule_del(ctx, cmd);
case CMD_OBJ_CHAIN:
- return netlink_flush_chain(ctx, cmd);
+ return mnl_nft_rule_del(ctx, cmd);
case CMD_OBJ_SET:
case CMD_OBJ_MAP:
case CMD_OBJ_METER: