commit | 063cfb2084ea4b12d3c85b2d2c44e888f0857eb4 | [log] [tgz] |
---|---|---|
author | Elliott Hughes <enh@google.com> | Thu Oct 25 20:55:23 2012 -0700 |
committer | Elliott Hughes <enh@google.com> | Fri Oct 26 16:42:06 2012 -0700 |
tree | ec94389e76f6fd79d573c4a689b7c83c4711edd0 | |
parent | 7193731ae6b8083bc7a5e5e468fb98b1dbcf3f3d [diff] [blame] |
Clean up the implementation of the <dirent.h> functions. Change-Id: I3c647cc9588525afc41fee90ee468d58cd13503a
diff --git a/libc/bionic/sysconf.c b/libc/bionic/sysconf.c index 7caa4e9..d21a703 100644 --- a/libc/bionic/sysconf.c +++ b/libc/bionic/sysconf.c
@@ -85,9 +85,8 @@ } int result = 0; - struct dirent de; struct dirent* e; - while (!readdir_r(d, &de, &e) && e != NULL) { + while ((e = readdir(d)) != NULL) { if (e->d_type == DT_DIR && __matches_cpuN(e->d_name)) { ++result; }