birthtime initialization

Bruce Evans brde at optusnet.com.au
Tue Jul 22 17:31:45 UTC 2008


On Tue, 22 Jul 2008, Pedro Giffuni wrote:

> Tim has some patches I made to add support for birthtime in libarchive (only in extended pax format) as a LIBARCHIVE.creationtime attribute.
>
> Since birthtime is set by modifying mtime twice with utimes(2), the only criteria I used to determine if birthtime should be stored is if it was less than mtime. I hope something can be done to make that behavior consistent with UFS2 in all other filesystems.

Can't it check for st_birthtime.tv_sec being != 0 or -1?  The erroneous
default of 0 might interact badly with file systems written by buggy
versions of tar that set times to 0.

Bruce


More information about the freebsd-fs mailing list