summaryrefslogtreecommitdiff
path: root/src/posix.h
diff options
context:
space:
mode:
Diffstat (limited to 'src/posix.h')
-rw-r--r--src/posix.h5
1 files changed, 3 insertions, 2 deletions
diff --git a/src/posix.h b/src/posix.h
index cc35c52e3..d423b7e07 100644
--- a/src/posix.h
+++ b/src/posix.h
@@ -84,9 +84,10 @@ extern int p_gettimeofday(struct timeval *tv, struct timezone *tz);
#endif
#ifndef NO_READDIR_R
-#define p_readdir_r(d,e,r) readdir_r(d,e,&r)
+#define p_readdir_r(d,e,r) readdir_r(d,e,r)
#else
-GIT_INLINE(int) p_readdir_r(DIR *dirp, struct dirent *entry, struct direct **result)
+#include <dirent.h>
+GIT_INLINE(int) p_readdir_r(DIR *dirp, struct dirent *entry, struct dirent **result)
{
GIT_UNUSED(entry);
*result = readdir(dirp);