aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/unix/sysv')
-rw-r--r--sysdeps/unix/sysv/linux/utime.c3
-rw-r--r--sysdeps/unix/sysv/linux/utimes.c3
2 files changed, 4 insertions, 2 deletions
diff --git a/sysdeps/unix/sysv/linux/utime.c b/sysdeps/unix/sysv/linux/utime.c
index 2cd9334a6f..8665ef2636 100644
--- a/sysdeps/unix/sysv/linux/utime.c
+++ b/sysdeps/unix/sysv/linux/utime.c
@@ -18,6 +18,7 @@
#include <utime.h>
#include <time.h>
+#include <fcntl.h>
int
__utime64 (const char *file, const struct __utimbuf64 *times)
@@ -32,7 +33,7 @@ __utime64 (const char *file, const struct __utimbuf64 *times)
ts64[1].tv_nsec = 0LL;
}
- return __utimensat64_helper (0, file, times ? ts64 : NULL, 0);
+ return __utimensat64_helper (AT_FDCWD, file, times ? ts64 : NULL, 0);
}
#if __TIMESIZE != 64
diff --git a/sysdeps/unix/sysv/linux/utimes.c b/sysdeps/unix/sysv/linux/utimes.c
index 75927b6ec6..a6809876fd 100644
--- a/sysdeps/unix/sysv/linux/utimes.c
+++ b/sysdeps/unix/sysv/linux/utimes.c
@@ -17,6 +17,7 @@
<https://www.gnu.org/licenses/>. */
#include <time.h>
+#include <fcntl.h>
int
__utimes64 (const char *file, const struct __timeval64 tvp[2])
@@ -29,7 +30,7 @@ __utimes64 (const char *file, const struct __timeval64 tvp[2])
ts64[1] = timeval64_to_timespec64 (tvp[1]);
}
- return __utimensat64_helper (0, file, tvp ? ts64 : NULL, 0);
+ return __utimensat64_helper (AT_FDCWD, file, tvp ? ts64 : NULL, 0);
}
#if __TIMESIZE != 64