#950519 gzip: please default to -n

Package:
gzip
Source:
gzip
Description:
GNU compression utilities
Submitter:
Adam Borowski
Date:
2021-03-01 05:51:02 UTC
Severity:
wishlist
Tags:
#950519#5
Date:
2020-02-02 22:58:05 UTC
From:
To:
Package: gzip
Version: 1.9-3
Severity: wishlist

Hi!
I've run ran into an Y2038 problem when compressing a file with a timestamp
after that date.  It's a yet another reason to drop including the timestamp
into .gz files -- something that no other popular compressor does.

It makes the output unreproducible for the same input.  This results in
having to manually add -n in thousands of places.

Then, it breaks logrotate:
error: Compressing program wrote following message to stderr when compressing log /var/log/exim4/mainlog.1:
gzip: stdin: warning: file timestamp out of range for gzip format
error: failed to compress log /var/log/exim4/mainlog.1
error: Compressing program wrote following message to stderr when compressing log /var/log/syslog.1:
gzip: stdin: warning: file timestamp out of range for gzip format
error: failed to compress log /var/log/syslog.1

We're working on Y2038 bugs all around the kernel, glibc, etc.  The time
such a fix would be strictly required for gzip is 18 years from now... but
why not flip the switch already?


Meow!

#950519#14
Date:
2021-03-01 05:05:34 UTC
From:
To:

Hi Adam,

Gzip can store a timestamp in the range from 1970-01-01 00:00:01 UTC
through 2106-02-07 06:28:15 UTC. If you are having trouble with
timestamps after 2038-01-19 03:14:07 UTC but not later than 2106-02-07
06:28:15 UTC, that is likely due to a limitation present at some other
place i.e. glibc, gcc, filesystem, kernel ...

Milan