ntdll: Add an futimens syscall wrapper for Android.
This commit is contained in:
parent
8b11533dcf
commit
61770be5f1
|
@ -36,6 +36,9 @@
|
||||||
#ifdef HAVE_SYS_PARAM_H
|
#ifdef HAVE_SYS_PARAM_H
|
||||||
# include <sys/param.h>
|
# include <sys/param.h>
|
||||||
#endif
|
#endif
|
||||||
|
#ifdef HAVE_SYS_SYSCALL_H
|
||||||
|
# include <sys/syscall.h>
|
||||||
|
#endif
|
||||||
#ifdef HAVE_SYS_TIME_H
|
#ifdef HAVE_SYS_TIME_H
|
||||||
# include <sys/time.h>
|
# include <sys/time.h>
|
||||||
#endif
|
#endif
|
||||||
|
@ -1654,6 +1657,15 @@ NTSTATUS WINAPI NtSetVolumeInformationFile(
|
||||||
return 0;
|
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 )
|
static NTSTATUS set_file_times( int fd, const LARGE_INTEGER *mtime, const LARGE_INTEGER *atime )
|
||||||
{
|
{
|
||||||
NTSTATUS status = STATUS_SUCCESS;
|
NTSTATUS status = STATUS_SUCCESS;
|
||||||
|
|
Loading…
Reference in New Issue