summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2019-11-22 11:28:31 +0100
committerDavid Oberhollenzer <david.oberhollenzer@sigma-star.at>2019-11-22 11:28:31 +0100
commitdd4d7e713290d9cecbebc6933e41d027bac63c8f (patch)
treee252c2ddce438e1dc80d05d30b1bedd620342a92 /include
parenteafaffa0f09b7c22eed906ef5356b1460d44da55 (diff)
Add fchownat/fchmodat mockups to libcompat for Windows
Not pretty, but definitely prettier than #ifdef hell. Signed-off-by: David Oberhollenzer <david.oberhollenzer@sigma-star.at>
Diffstat (limited to 'include')
-rw-r--r--include/compat.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/include/compat.h b/include/compat.h
index fae9d92..53c2e93 100644
--- a/include/compat.h
+++ b/include/compat.h
@@ -98,6 +98,13 @@ struct stat {
(((x)&0x00000fffULL) << 8) | \
(((y)&0xffffff00ULL) << 12) | \
(((y)&0x000000ffULL)) )
+
+#define AT_FDCWD (0xDEADBEEF)
+#define AT_SYMLINK_NOFOLLOW (0x01)
+
+int fchownat(int dirfd, const char *path, int uid, int gid, int flags);
+
+int fchmodat(int dirfd, const char *path, int mode, int flags);
#else
#include <sys/types.h>
#include <sys/stat.h>