summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source4/lib/replace/repdir_getdirentries.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/source4/lib/replace/repdir_getdirentries.c b/source4/lib/replace/repdir_getdirentries.c
index 33c63c3bcc..a9c1c1ce82 100644
--- a/source4/lib/replace/repdir_getdirentries.c
+++ b/source4/lib/replace/repdir_getdirentries.c
@@ -104,7 +104,13 @@ struct dirent *readdir(DIR *dir)
return de;
}
+#define TELLDIR_TAKES_CONST_DIR
+
+#ifdef TELLDIR_TAKES_CONST_DIR
+long telldir(const DIR *dir)
+#else
long telldir(DIR *dir)
+#endif
{
struct dir_buf *d = (struct dir_buf *)dir;
if (d->ofs >= d->nbytes) {