projects
/
pintos-anon
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
d6c587c
)
fixed typo in wrong iterator example
author
Godmar Back
<godmar@gmail.com>
Tue, 12 Sep 2006 02:32:27 +0000
(
02:32
+0000)
committer
Godmar Back
<godmar@gmail.com>
Tue, 12 Sep 2006 02:32:27 +0000
(
02:32
+0000)
src/lib/kernel/list.c
patch
|
blob
|
history
diff --git
a/src/lib/kernel/list.c
b/src/lib/kernel/list.c
index ecbb7cb6e36d6f4adab5a32cda7bfcf6db464266..e9993cbd0a5e6295d806a566b9ce4c8d76aa299c 100644
(file)
--- 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);