Module: wine Branch: master Commit: 61770be5f1d3f8c11025ed5ba8fa2902027eb58a URL: http://source.winehq.org/git/wine.git/?a=commit;h=61770be5f1d3f8c11025ed5ba8...
Author: Alexandre Julliard julliard@winehq.org Date: Tue Oct 29 10:24:34 2013 +0100
ntdll: Add an futimens syscall wrapper for Android.
---
dlls/ntdll/file.c | 12 ++++++++++++ 1 files changed, 12 insertions(+), 0 deletions(-)
diff --git a/dlls/ntdll/file.c b/dlls/ntdll/file.c index 9dbc8fe..8c8f4cf 100644 --- a/dlls/ntdll/file.c +++ b/dlls/ntdll/file.c @@ -36,6 +36,9 @@ #ifdef HAVE_SYS_PARAM_H # include <sys/param.h> #endif +#ifdef HAVE_SYS_SYSCALL_H +# include <sys/syscall.h> +#endif #ifdef HAVE_SYS_TIME_H # include <sys/time.h> #endif @@ -1654,6 +1657,15 @@ NTSTATUS WINAPI NtSetVolumeInformationFile( return 0; }
+#if defined(__ANDROID__) && !defined(HAVE_FUTIMENS) +static int futimens( int fd, const struct timespec spec[2] ) +{ + return syscall( __NR_utimensat, fd, NULL, spec, 0 ); +} +#define UTIME_OMIT ((1 << 30) - 2) +#define HAVE_FUTIMENS +#endif /* __ANDROID__ */ + static NTSTATUS set_file_times( int fd, const LARGE_INTEGER *mtime, const LARGE_INTEGER *atime ) { NTSTATUS status = STATUS_SUCCESS;