summaryrefslogtreecommitdiff
path: root/include/dirent.h
diff options
context:
space:
mode:
authorTodd C. Miller <millert@cvs.openbsd.org>2010-10-28 15:02:42 +0000
committerTodd C. Miller <millert@cvs.openbsd.org>2010-10-28 15:02:42 +0000
commitad39b297930f7aeb9f57f3283cb31dad08c3a9ac (patch)
tree686235f31d6eb66ef3d8180a61333f611d32602b /include/dirent.h
parent24c64c90c25711433236441e0509ebae8231f426 (diff)
Change basep parameter of getdirentries() to be off_t *, not long *
so it works correctly with large offsets (and matches other systems). This requires adding a new getdirentries syscall, with the old one renamed to ogetdirentries. All in-tree consumers of getdirentries() have been updated. Bump libc and libpthread major numbers. OK and with deraadt@
Diffstat (limited to 'include/dirent.h')
-rw-r--r--include/dirent.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/include/dirent.h b/include/dirent.h
index 20765d01c44..383048ab007 100644
--- a/include/dirent.h
+++ b/include/dirent.h
@@ -1,4 +1,4 @@
-/* $OpenBSD: dirent.h,v 1.18 2007/06/05 18:11:48 kurt Exp $ */
+/* $OpenBSD: dirent.h,v 1.19 2010/10/28 15:02:41 millert Exp $ */
/* $NetBSD: dirent.h,v 1.9 1995/03/26 20:13:37 jtc Exp $ */
/*-
@@ -67,8 +67,8 @@ typedef struct _dirdesc {
long dd_size; /* amount of data returned by getdirentries */
char *dd_buf; /* data buffer */
int dd_len; /* size of data buffer */
- long dd_seek; /* magic cookie returned by getdirentries */
- long dd_rewind; /* magic cookie for rewinding */
+ off_t dd_seek; /* magic cookie returned by getdirentries */
+ off_t dd_rewind; /* magic cookie for rewinding */
int dd_flags; /* flags for readdir */
struct _telldir *dd_td; /* telldir position recording */
void *dd_lock; /* mutex to protect struct */
@@ -104,7 +104,7 @@ DIR *__opendir2(const char *, int);
int scandir(const char *, struct dirent ***,
int (*)(struct dirent *), int (*)(const void *, const void *));
int alphasort(const void *, const void *);
-int getdirentries(int, char *, int, long *)
+int getdirentries(int, char *, int, off_t *)
__attribute__ ((__bounded__(__string__,2,3)));
#endif /* __BSD_VISIBLE */
#if __XPG_VISIBLE