From 1acc80f5d25689ca963b84911f2b47f8eddbd0d4 Mon Sep 17 00:00:00 2001 From: Ralf Corsepius Date: Mon, 16 Jul 2012 17:03:50 +0000 Subject: [PATCH] =?UTF-8?q?2012-07-16=20=20Ralf=20Cors=C3=A9pius=20=20?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit * libc/posix/telldir.c: Conditionally build dd_hash_lock. --- newlib/ChangeLog | 4 ++++ newlib/libc/posix/telldir.c | 3 +++ 2 files changed, 7 insertions(+) diff --git a/newlib/ChangeLog b/newlib/ChangeLog index 8acd7ab79..1d66d47c8 100644 --- a/newlib/ChangeLog +++ b/newlib/ChangeLog @@ -1,3 +1,7 @@ +2012-07-16 Ralf Corsépius + + * libc/posix/telldir.c: Conditionally build dd_hash_lock. + 2012-07-13 Ralf Corsépius * libc/sys/rtems/machine/_types.h (_ssize_t): Add __ARM_EABI__, diff --git a/newlib/libc/posix/telldir.c b/newlib/libc/posix/telldir.c index f2b1c79bd..caac4890b 100644 --- a/newlib/libc/posix/telldir.c +++ b/newlib/libc/posix/telldir.c @@ -69,7 +69,10 @@ struct ddloc { static long dd_loccnt = 1; /* Index of entry for sequential readdir's */ static struct ddloc *dd_hash[NDIRHASH]; /* Hash list heads for ddlocs */ + +#ifdef HAVE_DD_LOCK __LOCK_INIT(static, dd_hash_lock); +#endif /* * return a pointer into a directory