summaryrefslogtreecommitdiffstats
path: root/net
diff options
context:
space:
mode:
authorWei Yongjun <yongjun_wei@trendmicro.com.cn>2013-03-22 02:28:18 +0100
committerPablo Neira Ayuso <pablo@netfilter.org>2013-03-25 14:21:27 +0100
commit558724a5b2a73ad0c7638e21e8dffc419d267b6c (patch)
treec383c5907a40f74bc81e9370097243d4914d1ec4 /net
parentnetfilter: reset nf_trace in nf_reset (diff)
downloadlinux-558724a5b2a73ad0c7638e21e8dffc419d267b6c.tar.xz
linux-558724a5b2a73ad0c7638e21e8dffc419d267b6c.zip
netfilter: nfnetlink_queue: fix error return code in nfnetlink_queue_init()
Fix to return a negative error code from the error handling case instead of 0, as returned elsewhere in this function. Signed-off-by: Wei Yongjun <yongjun_wei@trendmicro.com.cn> Signed-off-by: Pablo Neira Ayuso <pablo@netfilter.org>
Diffstat (limited to 'net')
-rw-r--r--net/netfilter/nfnetlink_queue_core.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/net/netfilter/nfnetlink_queue_core.c b/net/netfilter/nfnetlink_queue_core.c
index 1cb48540f86a..42680b2baa11 100644
--- a/net/netfilter/nfnetlink_queue_core.c
+++ b/net/netfilter/nfnetlink_queue_core.c
@@ -1062,8 +1062,10 @@ static int __init nfnetlink_queue_init(void)
#ifdef CONFIG_PROC_FS
if (!proc_create("nfnetlink_queue", 0440,
- proc_net_netfilter, &nfqnl_file_ops))
+ proc_net_netfilter, &nfqnl_file_ops)) {
+ status = -ENOMEM;
goto cleanup_subsys;
+ }
#endif
register_netdevice_notifier(&nfqnl_dev_notifier);