bug-tar
[Top][All Lists]
Advanced

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

Re: [Bug-tar] Do not fail when 'compress' is unable to provide sufficien


From: Antonio Diaz Diaz
Subject: Re: [Bug-tar] Do not fail when 'compress' is unable to provide sufficient compress ratio
Date: Mon, 29 Apr 2013 20:27:16 +0200
User-agent: Mozilla/5.0 (X11; U; Linux i586; en-US; rv:1.7.11) Gecko/20050905

Paul Eggert wrote:
If you look at the gzip source code you'll
find a number of circumstances that will
cause it to exit with status 2, as a warning.

Then gzip's API differs from compress's API[1] (return 2 only if size increases and -f is not specified), and from "standard" API (only 0 means success).

[1]http://pubs.opengroup.org/onlinepubs/9699919799/utilities/compress.html

    The following exit values shall be returned:
     0  Successful completion.
     1  An error occurred.
2 One or more files were not compressed because they would have increased in size (and the -f option was not specified).
    >2  An error occurred.


This API isn't likely to change any time soon,
I'm afraid, as gzip is fairly frozen.

This is unfortunate because as quirks accumulate in GNU tar to accomodate the quirks of other programs it will become more bloated and more difficult to use. In short, less convenient for the user.

It really takes a tough man to make a tender chicken. :-(


Best regards,
Antonio.



reply via email to

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