systemd/debian/patches/delta-replace-readdir_r-with-readdir.patch
Jon Severinsson 87c3557857 Add v208-stable patch series.
This commit was created using the following commands and then fixing up debian/patches/series manually.
$ git config diff.renames false
$ git rebase --onto debian/208-5 v208 stable/v208-stable
$ git checkout -b patch-queue/experimental HEAD
$ gbp-pq export --no-patch-numbers
$ git add --ignore-removal debian/patches/
2014-07-07 12:29:26 +02:00

32 lines
984 B
Diff

From: Florian Weimer <fweimer@redhat.com>
Date: Thu, 19 Dec 2013 11:16:12 +0100
Subject: delta: replace readdir_r with readdir
(cherry picked from commit 6887ec4f00d7c10cd70da3e10d570684bf32d28d)
---
src/delta/delta.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
diff --git a/src/delta/delta.c b/src/delta/delta.c
index b3272d9..fd024fc 100644
--- a/src/delta/delta.c
+++ b/src/delta/delta.c
@@ -280,13 +280,13 @@ static int enumerate_dir(Hashmap *top, Hashmap *bottom, Hashmap *drops, const ch
for (;;) {
struct dirent *de;
- union dirent_storage buf;
int k;
char *p;
- k = readdir_r(d, &buf.de, &de);
- if (k != 0)
- return -k;
+ errno = 0;
+ de = readdir(d);
+ if (!de && errno != 0)
+ return -errno;
if (!de)
break;