All of lore.kernel.org
 help / color / mirror / Atom feed
* check_entry & module_refcount
@ 2006-09-04 12:17 Dmitry Mishin
  2006-09-04 13:40 ` Patrick McHardy
  2006-09-06  1:24 ` Yasuyuki KOZAKAI
  0 siblings, 2 replies; 6+ messages in thread
From: Dmitry Mishin @ 2006-09-04 12:17 UTC (permalink / raw)
  To: netfilter-devel

Hello, all!

Does anybody know why there is no module_put() on the error way after failed 
standard_check() call in the check_entry() function? Previous xt_find_target()
calls try_module_get() for all targets, without special checks for
standard_target.

If it is a bug, patch over net-2.6.19 is below.

Signed-off-by: Dmitry Mishin <dim@openvz.org>

--
 ip_tables.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

--- ./net/ipv4/netfilter/ip_tables.c.err	2006-08-30 13:12:13.000000000 +0400
+++ ./net/ipv4/netfilter/ip_tables.c	2006-09-04 16:01:11.000000000 +0400
@@ -573,7 +573,7 @@
 	if (t->u.kernel.target == &ipt_standard_target) {
 		if (!standard_check(t, size)) {
 			ret = -EINVAL;
-			goto cleanup_matches;
+			goto err;
 		}
 	} else if (t->u.kernel.target->checkentry
 		   && !t->u.kernel.target->checkentry(name, e, target, t->data,

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2006-09-07 15:02 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2006-09-04 12:17 check_entry & module_refcount Dmitry Mishin
2006-09-04 13:40 ` Patrick McHardy
2006-09-06  1:24 ` Yasuyuki KOZAKAI
2006-09-06 18:23   ` Patrick McHardy
2006-09-07 10:08     ` small check_entry & module_refcount cleanup Dmitry Mishin
2006-09-07 15:02       ` Patrick McHardy

This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.