]> git.ipfire.org Git - thirdparty/nftables.git/commit
src: improve error reporting for destroy command
author谢致邦 (XIE Zhibang) <Yeking@Red54.com>
Wed, 21 Feb 2024 15:17:09 +0000 (15:17 +0000)
committerFlorian Westphal <fw@strlen.de>
Tue, 27 Feb 2024 23:21:42 +0000 (00:21 +0100)
commitf27f032b8da584d4447dc03b3ccd3370433e2c0f
tree93e5e8db55e6b1c9ad60c96ddd751f8909812966
parente4f59f2dc68fb2e6d62a6c37e04366a8ebd199cf
src: improve error reporting for destroy command

Example for older kernels (<6.3):
nft destroy table ip missingtable

Before:
Error: Could not process rule: Invalid argument

After:
Error: "destroy" command is not supported, perhaps kernel support is
missing?

Fixes: e1dfd5cc4c46 ("src: add support to command "destroy"")
Signed-off-by: 谢致邦 (XIE Zhibang) <Yeking@Red54.com>
Signed-off-by: Florian Westphal <fw@strlen.de>
src/cmd.c