summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorStefan Metzmacher <metze@samba.org>2006-09-14 05:33:54 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 14:18:39 -0500
commitac24d381a5a9bc4611701bcbf956fe017bdddaeb (patch)
treee8b4e68288e2b8604a7c1cecd7a83e23e4ae51fe
parenta13360119256cc3d579cb8e936ffb35b2f6799cd (diff)
downloadsamba-ac24d381a5a9bc4611701bcbf956fe017bdddaeb.tar.gz
samba-ac24d381a5a9bc4611701bcbf956fe017bdddaeb.tar.bz2
samba-ac24d381a5a9bc4611701bcbf956fe017bdddaeb.zip
r18499: this hopefully lets the code compile on OpenBSD
the prototype was fixed in this revision http://www.openbsd.org/cgi-bin/cvsweb/src/include/dirent.h.diff?r1=1.15&r2=1.16 so we'll need a configure test to find the prototype of telldir later metze (This used to be commit c4da3b43640368aff98e501b6ca7801821fd2fbd)
-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) {