Re: POSIX ruling on up-to-date vs. identical timestamps

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Paul Smith wrote:
It's trivial to determine the filesystem in POSIX via the
device ID available from stat()

Yes, that's what the Gnulib utimecmp module does: the idea is that after every stat-like operation you look at the file's time stamps to infer more information about the containing file system's resolution.

As far as Windows goes, NTFS file systems have 100 ns resolution, and FAT file systems are the joker as they have a 2-second resolution for last-modified time.

While we're on the topic, perhaps I should warn you that in old buggy Linux kernels file time stamps could spontaneously be truncated to file system resolution. According to <https://gcc.gnu.org/ml/gcc/2004-04/msg00152.html> this bug was introduced into the Linux kernel in 2002; I don't recall when it was fixed in Linux, but a few years later POSIX prohibited the buggy behavior.

_______________________________________________
Autoconf mailing list
Autoconf@xxxxxxx
https://lists.gnu.org/mailman/listinfo/autoconf




[Index of Archives]     [GCC Help]     [Kernel Discussion]     [RPM Discussion]     [Red Hat Development]     [Yosemite News]     [Linux USB]     [Samba]

  Powered by Linux