From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: from relay.hostedemail.com (smtprelay0017.hostedemail.com [216.40.44.17]) by sourceware.org (Postfix) with ESMTPS id 66EB43858D39 for ; Wed, 10 Apr 2024 04:30:11 +0000 (GMT) DMARC-Filter: OpenDMARC Filter v1.4.2 sourceware.org 66EB43858D39 Authentication-Results: sourceware.org; dmarc=none (p=none dis=none) header.from=SystematicSW.ab.ca Authentication-Results: sourceware.org; spf=pass smtp.mailfrom=SystematicSW.ab.ca ARC-Filter: OpenARC Filter v1.0.0 sourceware.org 66EB43858D39 Authentication-Results: server2.sourceware.org; arc=none smtp.remote-ip=216.40.44.17 ARC-Seal: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1712723419; cv=none; b=D0xs8YvUUUExTbNQUgGacJY0RS7XYpPtHH/O+KjRmVXIVN9k1jWEI3Vf29iylV8Lk2oL5g3daCjxHEO/drR1mXN7SZ1PpNbUklJeRHrc2pDtBa/Jk6fLTPjYq7XUcZodJ1u4Q4mwYQONZZO6ul0hvmsyAJGkX7pgKpqxI1U5D3Q= ARC-Message-Signature: i=1; a=rsa-sha256; d=sourceware.org; s=key; t=1712723419; c=relaxed/simple; bh=cQyL6aQM33UI+mCL1VW2V0stzF8/JN6W+Hi9rh0Ep+Y=; h=Message-ID:Date:MIME-Version:Subject:To:From; b=nMl4U/OOfk0k3CZDZl29Q/fuixvAXI0CGwVTySC+lSNmC3930VNr/Jm9pysY32q37AlIS4/x1lZmBb2SCY/Me7fiy4RS8iwEjrF6LuWxK6ME1taJ5It2k2kR+Ih3Y5h90idvs+DoCBtvkuV/q2enVEnvz0zsyNEyVQVnefuCJlI= ARC-Authentication-Results: i=1; server2.sourceware.org Received: from omf13.hostedemail.com (a10.router.float.18 [10.200.18.1]) by unirelay01.hostedemail.com (Postfix) with ESMTP id DEFE21C0309 for ; Wed, 10 Apr 2024 04:30:10 +0000 (UTC) Received: from [HIDDEN] (Authenticated sender: Brian.Inglis@SystematicSW.ab.ca) by omf13.hostedemail.com (Postfix) with ESMTPA id 798612000D for ; Wed, 10 Apr 2024 04:30:08 +0000 (UTC) Message-ID: <5f0672aa-a33b-45fb-8ec6-826ad586bb66@SystematicSW.ab.ca> Date: Tue, 9 Apr 2024 22:30:07 -0600 MIME-Version: 1.0 User-Agent: Mozilla Thunderbird Reply-To: cygwin@cygwin.com Subject: Re: Win32 FILE_BASIC_INFORMATION.*Time.QuadPart - which value should be used if filesystem does not support it, so Cygwin /usr/bin/stat lists the value as '-'? Content-Language: en-CA To: cygwin@cygwin.com References: From: Brian Inglis Organization: Systematic Software In-Reply-To: Content-Type: text/plain; charset=UTF-8; format=flowed Content-Transfer-Encoding: 8bit X-Rspamd-Queue-Id: 798612000D X-Spam-Status: No, score=-2.1 required=5.0 tests=BAYES_00,KAM_DMARC_STATUS,RCVD_IN_DNSWL_NONE,RCVD_IN_MSPIKE_H3,RCVD_IN_MSPIKE_WL,SPF_HELO_PASS,SPF_PASS,TXREP,UNPARSEABLE_RELAY autolearn=ham autolearn_force=no version=3.4.6 X-Rspamd-Server: rspamout08 X-Stat-Signature: j4yncnf6ar53bqme8azjnfuz4qafn8wx X-Session-Marker: 427269616E2E496E676C69734053797374656D6174696353572E61622E6361 X-Session-ID: U2FsdGVkX1/Mw4ucY6JxbvZiZgZBV9H2ZUBePiU+Dco= X-HE-Tag: 1712723408-205671 X-HE-Meta: U2FsdGVkX190l2zH1RMlhJ0/zRKyyBACHSPO45IfOTFCbdgo8SuyO6S4D9CsonPgb6EU0FwY6UImrYcHQ95fbj03r5OqQl6dmQ1Z8pvLUktHgc3F+85oZiRlvSTUvqB9wKIhcBH2e/IGKE11w0PMiT1MEo3SBswurSz3ZbG+gtsnJk/BBlx51aZuqsrkJagilAlKW23IioZClwODrqGCiqQMtf0t1vZu1p/57NOm5Mo+Qr4aFMRdSil5hBkm6Y8n/DNaUt0lIPYBI0xneeLcc3T+j2NrAxeNmh0UCMevOxZRkqqDyGZ3VJ4quuDEyX8RNwUZiX0OV/p8fMvXqIsyvQmsA3vd5A+G2dIcONTYvFC3dUM8X5i6uAmKW6z/rkSCiI1W3yUgUSp0Tev1zBNfEYkH0XuTY9hyGSEbNyML9+I= X-Spam-Checker-Version: SpamAssassin 3.4.6 (2021-04-09) on server2.sourceware.org List-Id: On 2024-04-09 15:14, Corinna Vinschen via Cygwin wrote: > On Apr 5 04:26, Martin Wege via Cygwin wrote: >> On Fri, Apr 5, 2024 at 2:05 AM Martin Wege 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? >> >> In a related matter: >> The Win32 FILE_BASIC_INFORMATION structure defines four time values: >> >> LARGE_INTEGER CreationTime; >> LARGE_INTEGER LastAccessTime; >> LARGE_INTEGER LastWriteTime; >> LARGE_INTEGER ChangeTime; >> >> How can a filesystem indicate if it does not support a particular >> timestamp, such as ChangeTime? Should ChangeTime.QuadPart then be -1, >> -2 or 0, or another value? > > I'm not aware of a filesystem not supporting ChangeTime, that is, > st_ctime. Usually only CreationTime (st_birthtime) is missing. R/O media like CD/DVD-R or FS w/o write support? > I think setting the timestamp to 0 works for indicating that this kind > of timestamp is not supported. Cygwin is handling Windows timestamps > this way, but I can't find this in documentation ATM. See upthread?: 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 > But the FS driver can also just fill the CreationTime field with the > same value as LastWriteTime or ChangeTime. MSFT NFS does that. -- 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