From b861a707522e8625b4a5b4145b97a8825037572f Mon Sep 17 00:00:00 2001 From: "/C=EU/ST=EU/CN=Pablo Neira Ayuso/emailAddress=pablo@netfilter.org" Date: Tue, 15 Jan 2008 12:50:37 +0000 Subject: Max Kellermann Use list_for_each_entry() instead of list_for_each() --- src/conntrack.c | 4 +--- 1 file changed, 1 insertion(+), 3 deletions(-) (limited to 'src/conntrack.c') diff --git a/src/conntrack.c b/src/conntrack.c index 20d86f9..4f5fd0b 100644 --- a/src/conntrack.c +++ b/src/conntrack.c @@ -161,14 +161,12 @@ void register_proto(struct ctproto_handler *h) static struct ctproto_handler *findproto(char *name) { - struct list_head *i; struct ctproto_handler *cur = NULL, *handler = NULL; if (!name) return handler; - list_for_each(i, &proto_list) { - cur = (struct ctproto_handler *) i; + list_for_each_entry(cur, &proto_list, head) { if (strcmp(cur->name, name) == 0) { handler = cur; break; -- cgit v1.2.3