diff options
author | drh <drh@noemail.net> | 2018-01-12 14:34:45 +0000 |
---|---|---|
committer | drh <drh@noemail.net> | 2018-01-12 14:34:45 +0000 |
commit | 6ac7303e1ab5e0b224124e1c8f180cfa4d491e03 (patch) | |
tree | 21b3de85f8ab97029350dd655b667f6bd5f71cf6 /ext/misc/fileio.c | |
parent | f225059b8b674af30beeaf557873f7bb32d45ad4 (diff) | |
download | sqlite-6ac7303e1ab5e0b224124e1c8f180cfa4d491e03.tar.gz sqlite-6ac7303e1ab5e0b224124e1c8f180cfa4d491e03.zip |
Always use utimes() instead of utimensat() since the latter is not available
even on some recent unix systems.
FossilOrigin-Name: 30ed7a4b6408f0ca921abc4d8b7bb5404fc7708cedcd104b017b361054e7148c
Diffstat (limited to 'ext/misc/fileio.c')
-rw-r--r-- | ext/misc/fileio.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/misc/fileio.c b/ext/misc/fileio.c index f126a2e43..703588948 100644 --- a/ext/misc/fileio.c +++ b/ext/misc/fileio.c @@ -86,6 +86,7 @@ SQLITE_EXTENSION_INIT1 # include <unistd.h> # include <dirent.h> # include <utime.h> +# include <sys/time.h> #else # include "windows.h" # include <io.h> @@ -285,7 +286,7 @@ static int writeFile( }else{ return 1; } -#elif defined(AT_FDCWD) +#elif defined(AT_FDCWD) && 0 /* utimensat() is not univerally available */ /* Recent unix */ struct timespec times[2]; times[0].tv_nsec = times[1].tv_nsec = 0; |