summaryrefslogtreecommitdiffstats
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/pulsecore/llist.h3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/pulsecore/llist.h b/src/pulsecore/llist.h
index 58b51c68..27f174a9 100644
--- a/src/pulsecore/llist.h
+++ b/src/pulsecore/llist.h
@@ -107,4 +107,7 @@
#define PA_LLIST_FOREACH(i,head) \
for (i = (head); i; i = i->next)
+#define PA_LLIST_FOREACH_SAFE(i,n,head) \
+ for (i = (head); i && ((n = i->next), 1); i = n)
+
#endif