Added LINUX NOTES describing nanosecond timestamps.

This commit is contained in:
Michael Kerrisk 2005-11-17 13:36:31 +00:00
parent 817e5eab95
commit 246a500fe8
1 changed files with 14 additions and 0 deletions

View File

@ -247,6 +247,20 @@ The `sticky' bit (S_ISVTX) on a directory means that a file
in that directory can be renamed or deleted only by the owner
of the file, by the owner of the directory, and by a privileged
process.
.SH "LINUX NOTES"
Since kernel 2.5.48, the
.I stat
structure supports nanosecond resolution for the three
file timestamp fields.
Glibc exposes the nanosecond component of each field using names either
of the form
.IR st_atim.tv_nsec ,
if the _BSD_SOURCE or _SVID_SOURCE feature test macro is defined,
or of the form
.IR st_atimensec ,
if neither of these macros is defined.
On file systems that do not support sub-second timestamps,
these nanosecond fields are returned with the value 0.
.SH "RETURN VALUE"
On success, zero is returned. On error, \-1 is returned, and
.I errno