[BUG][Unix] ctime and mtime entries swapped in DirectoryEntry
David T. Lewis
lewis at mail.msen.com
Thu Oct 23 00:56:05 UTC 2003
On Wed, Oct 22, 2003 at 08:11:51AM -0700, Ned Konz wrote:
> On Wednesday 22 October 2003 6:34 am, Randal L. Schwartz wrote:
> > >>>>> "David" == David T Lewis <lewis at mail.msen.com> writes:
> >
> > David> Looks OK to me (on Linux, 3.6g-2 VM). My /etc/hosts shows a
> > creationTime earlier David> than modificationTime as expected.
> >
> > First, there's no such thing as creation time on Unix. So I have
> > no idea what the Unix VM is reporting.
>
> Of course, you're right. I was using the terms as in Squeak.
>
> > Second, if it's reporting ctime, the ctime is updated when the mtime
> > is updated, so absent a call to utime(2) (which sets the ctime to
> > "now" and the atime and mtime to arbitrary values), the ctime is
> > always the same or newer than the mtime. The rules are:
> >
> > atime - modified when file is opened for read, or via utime()
> > mtime - modified when file is opened for write, or via utime()
> > ctime - modified when file is opened for write, or when any
> > metadata is changed (renamed, linked, utime'd, chowned,
>
> Right. And what I was seeing in Squeak is that it was reporting the ctime
> rather than the mtime.
Ned, is there a specific problem you are trying to solve? I think we may be
getting into an "is it a feature or is it a bug" discussion relative to
Squeak's interpretation of a unix file system, but setting that aside for
the moment, is there anything we can help you with?
Dave
More information about the Squeak-dev
mailing list
|