From 04b1db625129936325474664d7f400b9993e9611 Mon Sep 17 00:00:00 2001 From: Godmar Back Date: Tue, 12 Sep 2006 02:32:27 +0000 Subject: [PATCH] fixed typo in wrong iterator example --- src/lib/kernel/list.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/lib/kernel/list.c b/src/lib/kernel/list.c index ecbb7cb..e9993cb 100644 --- a/src/lib/kernel/list.c +++ b/src/lib/kernel/list.c @@ -228,7 +228,7 @@ list_push_back (struct list *list, struct list_elem *elem) that a naive loop to remove the elements in a list will fail: ** DON'T DO THIS ** - for (e = list_begin (&list); e != list_end (&list); e = list_next (&list)) + for (e = list_begin (&list); e != list_end (&list); e = list_next (e)) { ...do something with e... list_remove (e); -- 2.30.2