bug-tar
[Top][All Lists]
Advanced

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[Bug-tar] make address@hidden a plausible time stamp


From: Denis Excoffier
Subject: [Bug-tar] make address@hidden a plausible time stamp
Date: Fri, 13 Sep 2013 19:54:22 +0200

Hello,

In src/extract.c, we can read the lines:

...
  if (t.tv_sec <= 0)
    WARNOPT (WARN_TIMESTAMP,
       (0, 0, _("%s: implausibly old time stamp %s"),
        file_name, tartime (t, true)));
...

This triggers the "implausibly old time stamp..." message at the 
extraction of any tarfile created with the option address@hidden On the 
other hand, the message is not triggered for a tarfile created with
address@hidden

I don't know if there are any strong requirements that the least
"plausible" time stamp to be "1".

I would suggest it to be "0" instead, because i know of some tarfiles:
- created with address@hidden
- for which the "implausibly old time stamp" message is unpleasant
  since this time stamp is agreed by both creater and extracter to not
  represent the date of the files

Indeed, such special tarfiles are used when it is needed to create
tarfiles as anonymous as possible. In this case, the options --owner=0,
--group=0, --numeric-owner and address@hidden are set to introduce as
little entropy as possible (also with the hope that the result will
compress better).

It can be observed that only the extracter is annoyed by the message
and that it is easy for them to extract with --touch (i.e. use the
current time). But the extracter would perhaps dislike that the files
on disk do not exactly reflect the files on the tarfile in this case.

Also, the potential problems with `find` (mentioned in
http://lists.gnu.org/archive/html/bug-tar/2004-01/msg00020.html) should
be gone now, and @0 can be a plain valid value, in any case
not especially implausible compared to @1. After all, "plausibility"
does not have a 1-second precision, i suppose.

Patch immediate. No impact in documentation nor in tests.

Regards,

Denis Excoffier.

P.S. Please also create soon a new release (in alpha.gnu.org?).





reply via email to

[Prev in Thread] Current Thread [Next in Thread]