nft_netlink function is already calling mnl_batch_end and
mnl_batch_begin so it is not necessary to do it in the
netlink_flush_rules function. Doing this result in a invalid
netlink message which is discarded by the kernel.
Signed-off-by: Eric Leblond <eric@regit.org>
Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
strerror(errno));
ctx->data = h;
- mnl_batch_begin();
nft_rule_list_foreach(rule_cache, flush_rule_cb, ctx);
nft_rule_list_free(rule_cache);
- mnl_batch_end();
return 0;
}