summaryrefslogtreecommitdiff
path: root/src/stat/mkdir.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/stat/mkdir.c')
-rw-r--r--src/stat/mkdir.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/stat/mkdir.c b/src/stat/mkdir.c
index 770e1ccc..32625b7d 100644
--- a/src/stat/mkdir.c
+++ b/src/stat/mkdir.c
@@ -1,7 +1,12 @@
#include <sys/stat.h>
+#include <fcntl.h>
#include "syscall.h"
int mkdir(const char *path, mode_t mode)
{
+#ifdef SYS_mkdir
return syscall(SYS_mkdir, path, mode);
+#else
+ return syscall(SYS_mkdirat, AT_FDCWD, path, mode);
+#endif
}