poll tests: Avoid test failure on BSD and Solaris systems.
[gnulib.git] / doc / posix-functions / utime.texi
blob4e41e5d52c5b4dbfa40e85e362700679699c55c5
1 @node utime
2 @section @code{utime}
3 @findex utime
5 POSIX specification:@* @url{https://pubs.opengroup.org/onlinepubs/9699919799/functions/utime.html}
7 Gnulib module: utime
9 Portability problems fixed by Gnulib:
10 @itemize
11 @item
12 The times that are set on the file are affected by the current time zone and
13 by the DST flag of the current time zone on some platforms:
14 mingw, MSVC 14 (when the environment variable @code{TZ} is set).
15 @item
16 On some platforms, the prototype for @code{utime} omits @code{const}
17 for the second argument:
18 mingw, MSVC 14.
19 @item
20 On some platforms, @code{utime("link-to-file/",buf)} succeeds instead
21 of failing with @code{ENOTDIR}.
22 Mac OS X 10.13.
23 @end itemize
25 Portability problems not fixed by Gnulib:
26 @itemize
27 @item
28 On some platforms, this function mis-handles trailing slash:
29 Solaris 9.
30 @item
31 This function cannot set full timestamp resolution.  Use
32 @code{utimensat(AT_FDCWD,file,times,0)}, or the gnulib module @code{utimens},
33 instead.
34 @end itemize