summaryrefslogtreecommitdiff
path: root/include/dirent.h
diff options
context:
space:
mode:
authorMike Frysinger <vapier@gentoo.org>2009-07-20 13:36:52 -0400
committerMike Frysinger <vapier@gentoo.org>2009-07-20 13:36:52 -0400
commitfd72e3042517f3c95ab2d707e1074f4d393b5f9a (patch)
tree37928d802bfb8cfd55ea49dcb16fe03091093e65 /include/dirent.h
parent91f91bcb3abda3780347d681c3bef6201b9ca60f (diff)
first pass at implementing *at funcs
Tested basic functionality with coreutils and things seem to work. At least gives us a basis to jump from. Signed-off-by: Mike Frysinger <vapier@gentoo.org>
Diffstat (limited to 'include/dirent.h')
-rw-r--r--include/dirent.h10
1 files changed, 9 insertions, 1 deletions
diff --git a/include/dirent.h b/include/dirent.h
index d4fc5c7d9..a9ff465f6 100644
--- a/include/dirent.h
+++ b/include/dirent.h
@@ -135,6 +135,14 @@ typedef struct __dirstream DIR;
extern DIR *opendir (__const char *__name) __nonnull ((1));
libc_hidden_proto(opendir)
+#ifdef __USE_XOPEN2K8
+/* Same as opendir, but open the stream on the file descriptor FD.
+
+ This function is a possible cancellation point and therefore not
+ marked with __THROW. */
+extern DIR *fdopendir (int __fd);
+#endif
+
/* Close the directory stream DIRP.
Return 0 if successful, -1 if not.
@@ -216,7 +224,7 @@ extern void seekdir (DIR *__dirp, long int __pos) __THROW __nonnull ((1));
extern long int telldir (DIR *__dirp) __THROW __nonnull ((1));
#endif
-#if defined __USE_BSD || defined __USE_MISC
+#if defined __USE_BSD || defined __USE_MISC || defined __XOPEN_2K8
/* Return the file descriptor used by DIRP. */
extern int dirfd (DIR *__dirp) __THROW __nonnull ((1));