summaryrefslogtreecommitdiff
path: root/src/shared/conf-files.c
diff options
context:
space:
mode:
authorFlorian Weimer <fweimer@redhat.com>2013-12-19 11:33:09 +0100
committerZbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl>2013-12-21 18:35:55 -0500
commita2be63f9223ed1503ffc1e99bf21eee25e4ae014 (patch)
tree5d9cb3e8c50daa49ed511a17da54b5502f890943 /src/shared/conf-files.c
parent0371ca0dac1d70b2e5060a3c4e6fbbc2bdbd8671 (diff)
conf-files: replace readdir_r with readdir
Diffstat (limited to 'src/shared/conf-files.c')
-rw-r--r--src/shared/conf-files.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/shared/conf-files.c b/src/shared/conf-files.c
index 92204a6a09..c86bb03074 100644
--- a/src/shared/conf-files.c
+++ b/src/shared/conf-files.c
@@ -53,13 +53,13 @@ static int files_add(Hashmap *h, const char *root, const char *path, const char
for (;;) {
struct dirent *de;
- union dirent_storage buf;
char *p;
int r;
- r = readdir_r(dir, &buf.de, &de);
- if (r != 0)
- return -r;
+ errno = 0;
+ de = readdir(dir);
+ if (!de && errno != 0)
+ return -errno;
if (!de)
break;