projects
/
project
/
netifd.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
13ec81c
)
add vlist_for_each_element iterator
author
Felix Fietkau
<nbd@openwrt.org>
Sun, 2 Oct 2011 18:31:44 +0000
(20:31 +0200)
committer
Felix Fietkau
<nbd@openwrt.org>
Sun, 2 Oct 2011 18:31:44 +0000
(20:31 +0200)
utils.h
patch
|
blob
|
history
diff --git
a/utils.h
b/utils.h
index 31fcd1f090bac56f3c22d0cede6e62d0bd39271a..d71a8f7489f411a38c164c047efe770f6978d0ee 100644
(file)
--- a/
utils.h
+++ b/
utils.h
@@
-48,6
+48,9
@@
void vlist_delete(struct vlist_tree *tree, struct vlist_node *node);
void vlist_flush(struct vlist_tree *tree);
void vlist_flush_all(struct vlist_tree *tree);
+#define vlist_for_each_element(tree, element, node_member) \
+ avl_for_each_element(&(tree)->avl, element, node_member.avl)
+
#ifdef __linux__
static inline int fls(int x)
{