diff options
| author | Carmelo Amoroso <carmelo.amoroso@st.com> | 2008-09-03 10:03:29 +0000 |
|---|---|---|
| committer | Carmelo Amoroso <carmelo.amoroso@st.com> | 2008-09-03 10:03:29 +0000 |
| commit | 7410da5e36a173772e7fd831933ea946759e4996 (patch) | |
| tree | f4fe6d924e25716b3638621099473443e2bd1dd4 /libc | |
| parent | 9a3a4b3b3a4451b57d833e0d7dc91b7a14138e43 (diff) | |
| download | uClibc-alpine-7410da5e36a173772e7fd831933ea946759e4996.tar.bz2 uClibc-alpine-7410da5e36a173772e7fd831933ea946759e4996.tar.xz | |
Make sure that multi-threaded statically linked applications use the real
locking implementations instead of the empty stubs from libc.a.
Removed also old work-around added to opendir, due to wrong
pthread_mutex_init (from libc.a) used in static binaries.
Signed-off-by: Filippo Arcidiacono <filippo.arcidiacono@st.com>
Signed-off-by: Carmelo Amoroso <carmelo.amoroso@st.com>
Diffstat (limited to 'libc')
| -rw-r--r-- | libc/misc/dirent/opendir.c | 3 |
1 files changed, 1 insertions, 2 deletions
diff --git a/libc/misc/dirent/opendir.c b/libc/misc/dirent/opendir.c index 8577d0703..e431e1978 100644 --- a/libc/misc/dirent/opendir.c +++ b/libc/misc/dirent/opendir.c @@ -75,9 +75,8 @@ close_and_ret: if (!(ptr = malloc(sizeof(*ptr)))) goto nomem_close_and_ret; - memset(ptr, '\0', sizeof(DIR)); ptr->dd_fd = fd; - + ptr->dd_nextloc = ptr->dd_size = ptr->dd_nextoff = 0; ptr->dd_max = statbuf.st_blksize; if (ptr->dd_max < 512) ptr->dd_max = 512; |
