ls -t changes the cygwin-access time of a file
Ronald Fischer
ynnor@mm.st
Tue Apr 11 05:16:00 GMT 2017
I'm running on Windows 7 64bit, the disk has NTFS, and I have Windows
enabled to track the correct file access time.
With Cygwin, I see the following oddity:
-0-1- ~/gitwrk/vp5 > ls -lu c:/tmp/x*
-rw-r--r-- 1 FISRONA Domain Users 10 Apr 11 06:59 c:/tmp/xx
(waiting a couple of minutes)
-0-1- ~/gitwrk/vp5 > ls -lut c:/tmp/x*
-rw-r--r-- 1 FISRONA Domain Users 10 Apr 11 07:01 c:/tmp/xx
I didn't touch the file in between, but the reported access time
changed. Further experimentation shows, that the reported access time
changes as soon as I use the -t option with ls. As long as I just do ls
-lu, the access time does not change.
Next, I double-checked in a Windows CMD shell:
C:\tmp>dir /TA xx
Datenträger in Laufwerk C: ist SYSTEM
Volumeseriennummer: B44F-4301
Verzeichnis von C:\tmp
11.04.2017 06:56 10 xx
1 Datei(en), 10 Bytes
0 Verzeichnis(se), 272.844.148.736 Bytes frei
We can see that the access time reported by Windows is *different* from
the one reported by Cygwin.
We hence have, what I believe, two bugs: The access time reported by the
-u option of Cygwin is, at least sometimes, incorrect, and using -t on
ls causes Cygwin to subsequently report a different access time.
Ronald
-------------- next part --------------
A non-text attachment was scrubbed...
Name: cygcheck.out
Type: application/octet-stream
Size: 484370 bytes
Desc: not available
URL: <http://cygwin.com/pipermail/cygwin/attachments/20170411/7139d2a8/attachment.obj>
-------------- next part --------------
--
Problem reports: http://cygwin.com/problems.html
FAQ: http://cygwin.com/faq/
Documentation: http://cygwin.com/docs.html
Unsubscribe info: http://cygwin.com/ml/#unsubscribe-simple
More information about the Cygwin
mailing list