diff options
author | Pablo Neira Ayuso <pablo@netfilter.org> | 2007-03-15 00:41:28 +0100 |
---|---|---|
committer | David S. Miller <davem@sunset.davemloft.net> | 2007-04-26 07:25:49 +0200 |
commit | ac0f1d9894650d900af99bdaed83e110d9dce025 (patch) | |
tree | bb105c1622fa5dada9b9aa40d3ac76aa20b5a0f8 | |
parent | [NETFILTER]: nfnetlink: remove duplicate checks in nfnetlink_check_attributes (diff) | |
download | linux-ac0f1d9894650d900af99bdaed83e110d9dce025.tar.xz linux-ac0f1d9894650d900af99bdaed83e110d9dce025.zip |
[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@netfilter.org>
Signed-off-by: Patrick McHardy <kaber@trash.net>
Signed-off-by: David S. Miller <davem@davemloft.net>
-rw-r--r-- | 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 9d33807ec16d..0b0a9666f6f9 100644 --- a/net/netfilter/nfnetlink.c +++ b/net/netfilter/nfnetlink.c @@ -94,8 +94,7 @@ static inline struct nfnetlink_subsystem *nfnetlink_get_subsys(u_int16_t type) { 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]; |