Hacker Newsnew | past | comments | ask | show | jobs | submitlogin

The `touch` example is there to show another instance of unexpected behavior: `touch test.exe test` only creates `test.exe`.


It seems that the archivers ask "does test exist" and when answered "yes" perform "delete test" which by cygwin >=1.7 actually deletes test.exe? Or even worse, the "open test" with some flag results in deleting test.exe and creating test.

But it also seems that touch asks "does test exist" and when answered yes it doesn't create it, just changes the datetime. Which probably changes the datetime of test.exe?

Anyway it would be good to investigate which actual calls by the user applications are being made in each case, to know what the actual sequence in each case is.




Consider applying for YC's Summer 2026 batch! Applications are open till May 4

Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: