From a22bca12d17d8701f4bed7490996458c38dcb657 Mon Sep 17 00:00:00 2001 From: tytung Date: Sat, 26 Mar 2011 13:01:49 +0800 Subject: [PATCH] Revert "netfilter: nf_log: avoid oops in (un)bind with invalid nfproto values" This reverts commit 895493dad60f71c1b71bf86b7aaf1e310d86c245. --- net/netfilter/nf_log.c | 4 ---- 1 file changed, 4 deletions(-) diff --git a/net/netfilter/nf_log.c b/net/netfilter/nf_log.c index e54392ee..d65d3481 100644 --- a/net/netfilter/nf_log.c +++ b/net/netfilter/nf_log.c @@ -83,8 +83,6 @@ EXPORT_SYMBOL(nf_log_unregister); int nf_log_bind_pf(u_int8_t pf, const struct nf_logger *logger) { - if (pf >= ARRAY_SIZE(nf_loggers)) - return -EINVAL; mutex_lock(&nf_log_mutex); if (__find_logger(pf, logger->name) == NULL) { mutex_unlock(&nf_log_mutex); @@ -98,8 +96,6 @@ EXPORT_SYMBOL(nf_log_bind_pf); void nf_log_unbind_pf(u_int8_t pf) { - if (pf >= ARRAY_SIZE(nf_loggers)) - return; mutex_lock(&nf_log_mutex); rcu_assign_pointer(nf_loggers[pf], NULL); mutex_unlock(&nf_log_mutex);