[NETFILTER 12/22]: nfnetlink: remove unrequired check in
nfnetlink_get_subsys
Patrick McHardy
kaber at trash.net
Wed Mar 14 09:50:34 CET 2007
[NETFILTER]: nfnetlink: remove unrequired check in nfnetlink_get_subsys
subsys_table is initialized to NULL, therefore just returns NULL in case
that it is not set.
Signed-off-by: Pablo Neira Ayuso <pablo at netfilter.org>
Signed-off-by: Patrick McHardy <kaber at trash.net>
---
commit bc5959a6bd9a56d1ea0e31344bde2b4f119d8b4c
tree 7c56a7256ee573e38f4a480dd7b8f6412e7e29bc
parent 6399e6156d65ce163cc77aeb6d53eacf9d9a1fb2
author Pablo Neira Ayuso <pablo at netfilter.org> Thu, 08 Mar 2007 18:25:37 +0100
committer Patrick McHardy <kaber at trash.net> Wed, 14 Mar 2007 09:31:09 +0100
net/netfilter/nfnetlink.c | 3 +--
1 files changed, 1 insertions(+), 2 deletions(-)
diff --git a/net/netfilter/nfnetlink.c b/net/netfilter/nfnetlink.c
index 9d33807..0b0a966 100644
--- a/net/netfilter/nfnetlink.c
+++ b/net/netfilter/nfnetlink.c
@@ -94,8 +94,7 @@ static inline struct nfnetlink_subsystem
{
u_int8_t subsys_id = NFNL_SUBSYS_ID(type);
- if (subsys_id >= NFNL_SUBSYS_COUNT
- || subsys_table[subsys_id] == NULL)
+ if (subsys_id >= NFNL_SUBSYS_COUNT)
return NULL;
return subsys_table[subsys_id];
More information about the netfilter-devel
mailing list