summaryrefslogtreecommitdiff
path: root/net
diff options
context:
space:
mode:
authorPablo Neira Ayuso <pablo@netfilter.org>2021-08-03 01:15:53 +0300
committerPablo Neira Ayuso <pablo@netfilter.org>2021-08-06 18:07:40 +0300
commit61e0c2bc555a194ada2632fadac73f2bdb5df9cb (patch)
tree269bc95e95631a4e6a75b07253a391e04da18029 /net
parent4608fdfc07e116f9fc0895beb40abad7cdb5ee3d (diff)
downloadlinux-61e0c2bc555a194ada2632fadac73f2bdb5df9cb.tar.xz
netfilter: nfnetlink_hook: strip off module name from hookfn
NFNLA_HOOK_FUNCTION_NAME should include the hook function name only, the module name is already provided by NFNLA_HOOK_MODULE_NAME. Fixes: e2cf17d3774c ("netfilter: add new hook nfnl subsystem") Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'net')
-rw-r--r--net/netfilter/nfnetlink_hook.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/net/netfilter/nfnetlink_hook.c b/net/netfilter/nfnetlink_hook.c
index 202f57d17bab..ca453c61dbdf 100644
--- a/net/netfilter/nfnetlink_hook.c
+++ b/net/netfilter/nfnetlink_hook.c
@@ -135,6 +135,7 @@ static int nfnl_hook_dump_one(struct sk_buff *nlskb,
if (module_name) {
char *end;
+ *module_name = '\0';
module_name += 2;
end = strchr(module_name, ']');
if (end) {