[netfilter-cvslog] r3486 - trunk/nfsim/core

rusty at netfilter.org rusty at netfilter.org
Wed Dec 22 05:05:35 CET 2004


Author: rusty at netfilter.org
Date: 2004-12-22 05:05:35 +0100 (Wed, 22 Dec 2004)
New Revision: 3486

Modified:
   trunk/nfsim/core/core.c
Log:
Fail sockopt registrations.


Modified: trunk/nfsim/core/core.c
===================================================================
--- trunk/nfsim/core/core.c	2004-12-22 02:54:47 UTC (rev 3485)
+++ trunk/nfsim/core/core.c	2004-12-22 04:05:35 UTC (rev 3486)
@@ -506,6 +506,7 @@
 	return ip_rcv_local(skb);
 }
 
+/* Don't do should_i_fail() here: it doesn't actually ever fail. */
 int __nf_register_hook_wrapper(struct nf_hook_ops *reg, struct module *owner,
 			       const char *location)
 {
@@ -536,6 +537,9 @@
 		     reg->owner->name, reg->owner);
 	reg->owner = owner;
 
+	if (should_i_fail(location))
+		return -EINTR;
+
 	ret = __nf_register_sockopt(reg);
 	if (ret == 0)
 		field_attach_static(reg, location, NULL);




More information about the netfilter-cvslog mailing list