From: Tom Gundersen Date: Sat, 26 Oct 2013 14:41:22 +0000 (+0200) Subject: STRV_FOREACH_BACKWARDS: improve readability a bit X-Git-Tag: v209~1779 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?p=elogind.git;a=commitdiff_plain;h=ca5c4105733ea439f89b0199cd3f92bc2f2a0b38 STRV_FOREACH_BACKWARDS: improve readability a bit The indentation was wrong, also put the semicolon on a separate line to make it clear it is a for-loop with an epmyt body. --- diff --git a/src/shared/strv.h b/src/shared/strv.h index 571ea38a7..cccf2e6a9 100644 --- a/src/shared/strv.h +++ b/src/shared/strv.h @@ -75,8 +75,9 @@ bool strv_overlap(char **a, char **b) _pure_; for ((s) = (l); (s) && *(s); (s)++) #define STRV_FOREACH_BACKWARDS(s, l) \ - STRV_FOREACH(s, l) ; \ - for ((s)--; (l) && ((s) >= (l)); (s)--) + STRV_FOREACH(s, l) \ + ; \ + for ((s)--; (l) && ((s) >= (l)); (s)--) #define STRV_FOREACH_PAIR(x, y, l) \ for ((x) = (l), (y) = (x+1); (x) && *(x) && *(y); (x) += 2, (y) = (x + 1))