Re: Cygwin /usr/bin/stat returns "Birth: -", which value in FILE_BASIC_INFORMATION.CreationTime causes that?
On 2024-04-04 19:08, Martin Wege via Cygwin wrote: On Fri, Apr 5, 2024 at 2:55 AM Brian Inglis via Cygwin wrote: On 2024-04-04 18:05, Martin Wege via Cygwin wrote: I have problems with debugging, so a quick help would be appreciated, as I cannot figure this out after several hours of digging. Cygwin /usr/bin/stat returns "Birth: -" for some files. Which value must the CreationTime member of FILE_BASIC_INFORMATION have to cause /usr/bin/stat ti return "-"? 0, -1, or something else? https://git.savannah.gnu.org/cgit/coreutils.git/tree/src/stat.c#n1618 => tv_nsec < 0 https://cygwin.com/git?p=newlib-cygwin.git;a=blob;f=winsup/cygwin/fhandler/disk_file.cc#l414 https://cygwin.com/git/?p=newlib-cygwin.git;a=blob;f=winsup/cygwin/times.cc#l283 Thank you But how can tv_nsec become negative (tv_nsec < 0)? That can only happen if BasicInformation.CreationTime.QuadPart is negative, right? Caller or application can set 0 to mean keep/return current value, caller or driver can set -1 to mean don't update/return current value: https://learn.microsoft.com/en-us/windows-hardware/drivers/ddi/wdm/ns-wdm-_file_basic_information#remarks -- Take care. Thanks, Brian Inglis Calgary, Alberta, Canada La perfection est atteinte Perfection is achieved non pas lorsqu'il n'y a plus rien à ajouter not when there is no more to add mais lorsqu'il n'y a plus rien à retirer but when there is no more to cut -- Antoine de Saint-Exupéry -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation:https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
Re: Cygwin /usr/bin/stat returns "Birth: -", which value in FILE_BASIC_INFORMATION.CreationTime causes that?
On Fri, Apr 5, 2024 at 2:55 AM Brian Inglis via Cygwin wrote: > > On 2024-04-04 18:05, Martin Wege via Cygwin wrote: > > I have problems with debugging, so a quick help would be appreciated, > > as I cannot figure this out after several hours of digging. > > > > Cygwin /usr/bin/stat returns "Birth: -" for some files. Which value > > must the CreationTime member of FILE_BASIC_INFORMATION have to cause > > /usr/bin/stat ti return "-"? 0, -1, or something else? > > https://git.savannah.gnu.org/cgit/coreutils.git/tree/src/stat.c#n1618 > > => tv_nsec < 0 > > https://cygwin.com/git?p=newlib-cygwin.git;a=blob;f=winsup/cygwin/fhandler/disk_file.cc#l414 > > https://cygwin.com/git/?p=newlib-cygwin.git;a=blob;f=winsup/cygwin/times.cc#l283 Thank you But how can tv_nsec become negative (tv_nsec < 0)? That can only happen if BasicInformation.CreationTime.QuadPart is negative, right? Thanks, Martin -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation:https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
Re: Cygwin /usr/bin/stat returns "Birth: -", which value in FILE_BASIC_INFORMATION.CreationTime causes that?
On 2024-04-04 18:05, Martin Wege via Cygwin wrote: I have problems with debugging, so a quick help would be appreciated, as I cannot figure this out after several hours of digging. Cygwin /usr/bin/stat returns "Birth: -" for some files. Which value must the CreationTime member of FILE_BASIC_INFORMATION have to cause /usr/bin/stat ti return "-"? 0, -1, or something else? https://git.savannah.gnu.org/cgit/coreutils.git/tree/src/stat.c#n1618 => tv_nsec < 0 https://cygwin.com/git?p=newlib-cygwin.git;a=blob;f=winsup/cygwin/fhandler/disk_file.cc#l414 https://cygwin.com/git/?p=newlib-cygwin.git;a=blob;f=winsup/cygwin/times.cc#l283 -- Take care. Thanks, Brian Inglis Calgary, Alberta, Canada La perfection est atteinte Perfection is achieved non pas lorsqu'il n'y a plus rien à ajouter not when there is no more to add mais lorsqu'il n'y a plus rien à retirer but when there is no more to cut -- Antoine de Saint-Exupéry -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation:https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple
Cygwin /usr/bin/stat returns "Birth: -", which value in FILE_BASIC_INFORMATION.CreationTime causes that?
Hello, I have problems with debugging, so a quick help would be appreciated, as I cannot figure this out after several hours of digging. Cygwin /usr/bin/stat returns "Birth: -" for some files. Which value must the CreationTime member of FILE_BASIC_INFORMATION have to cause /usr/bin/stat ti return "-"? 0, -1, or something else? Thanks, Martin -- Problem reports: https://cygwin.com/problems.html FAQ: https://cygwin.com/faq/ Documentation:https://cygwin.com/docs.html Unsubscribe info: https://cygwin.com/ml/#unsubscribe-simple