summaryrefslogtreecommitdiff
path: root/usr/src/uts/common/sys
diff options
context:
space:
mode:
Diffstat (limited to 'usr/src/uts/common/sys')
-rw-r--r--usr/src/uts/common/sys/fcntl.h7
-rw-r--r--usr/src/uts/common/sys/file.h1
2 files changed, 6 insertions, 2 deletions
diff --git a/usr/src/uts/common/sys/fcntl.h b/usr/src/uts/common/sys/fcntl.h
index 3167fd4a1d..cf55ebbf2a 100644
--- a/usr/src/uts/common/sys/fcntl.h
+++ b/usr/src/uts/common/sys/fcntl.h
@@ -86,6 +86,9 @@ extern "C" {
#define O_NOFOLLOW 0x20000 /* don't follow symlinks */
#define O_NOLINKS 0x40000 /* don't allow multiple hard links */
#define O_CLOEXEC 0x800000 /* set the close-on-exec flag */
+#if !defined(_STRICT_SYMBOLS) || defined(_XPG7)
+#define O_DIRECTORY 0x1000000 /* fail if not a directory */
+#endif
/*
* fcntl(2) requests
@@ -181,7 +184,7 @@ extern "C" {
#endif /* _STRICT_SYMBOLS */
#endif /* _LP64 || _FILE_OFFSET_BITS == 32 */
-#if defined(_LARGEFILE64_SOURCE)
+#if defined(_LARGEFILE64_SOURCE)
#if !defined(_LP64) || defined(_KERNEL)
/*
@@ -260,7 +263,7 @@ typedef struct flock32 {
/* transitional large file interface version */
-#if defined(_LARGEFILE64_SOURCE)
+#if defined(_LARGEFILE64_SOURCE)
typedef struct flock64 {
short l_type;
diff --git a/usr/src/uts/common/sys/file.h b/usr/src/uts/common/sys/file.h
index ec0741fe08..36e14f0c7a 100644
--- a/usr/src/uts/common/sys/file.h
+++ b/usr/src/uts/common/sys/file.h
@@ -118,6 +118,7 @@ typedef struct fpollinfo {
#define FEXEC 0x400000 /* O_EXEC = 0x400000 */
#define FCLOEXEC 0x800000 /* O_CLOEXEC = 0x800000 */
+#define FDIRECTORY 0x1000000 /* O_DIRECTORY = 0x1000000 */
#if defined(_KERNEL) || defined(_FAKE_KERNEL)