Code

Make flow more obvious
authorDagobert Michelsen <dam@opencsw.org>
Thu, 28 May 2015 12:02:16 +0000 (14:02 +0200)
committerDagobert Michelsen <dam@opencsw.org>
Thu, 28 May 2015 12:02:16 +0000 (14:02 +0200)
src/zone.c

index b8cc9197c2de5eea70990a1e4209b7f284a8d292..cb3869d69829ff04e8f908711faecf435a26602e 100644 (file)
@@ -155,7 +155,8 @@ zone_scandir(DIR *procdir)
                return(NULL);
        }
 
-       for (rewinddir(procdir); (direntp = readdir(procdir)); ) {
+       rewinddir(procdir);
+       while ((direntp = readdir(procdir))) {
                pidstr = direntp->d_name;
                if (pidstr[0] == '.')   /* skip "." and ".."  */
                        continue;