* NEWS: Describe gzexe changes noted below.
authorPaul Eggert <eggert@cs.ucla.edu>
Fri, 1 Dec 2006 20:52:52 +0000 (20:52 +0000)
committerPaul Eggert <eggert@cs.ucla.edu>
Fri, 1 Dec 2006 20:52:52 +0000 (20:52 +0000)
commit873e56c3ba906ae217d25e85d7515e8f4c775e32
tree297a0996d95686a314392427d442d35c5bea73ff
parentd28d9e4506cd5f353766535f9d9460cb28eb9b72
* NEWS: Describe gzexe changes noted below.
* Makefile.am (.in): Don't bother with SEDCMD.  This stuff isn't needed
any more (the hosts it caters to are long extinct), and was questionable
anyway since the code assumes the skip= line was line 2.
* configure.ac (AC_SYS_INTERPRETER, SEDCMD): Remove; no longer needed.

* gzexe.in: Sweep the code and fix some bugs.
My, what sharp teeth you have, gzexe!
The straw that broke this camel's back was Matthew Burgess's bug report
<http://lists.gnu.org/archive/html/bug-gzip/2006-11/msg00012.html>.

(IFS): Set it to the standard value, both here and in the
script gzexe generates.
Check for missing operand after parsing options, not before.
This fixes the case for "cpexe --".
Check for tail -n problem separately in gzexe and in the executable
it generates, in case it's a different 'tail'.
(trap): Remove $tmp only if $tmp is not the empty string.
Preserve exit status.
Don't use the nonstandard (and rarely available) "cpmod" utility.
Don't use "set -C"; it's no longer useful and it breaks things
in some cases.
(main loop): Handle file names beginning with "-".
Exit with status of failing program, not with 1.
Fix some bugs in printing diagnostics, and in quoting.
Require the skip= line to have at least one digit.
Use test -u and test -g rather than using the (less-reliable) ls.
Refuse to compress more programs, e.g., sh.
Use mktemp rather than tempfile.  Build a copy of
the compressed or uncompressed executable in the same
directory as the executable, as that's less likely to go wrong
if disk space is low.  Have the executable exit with status 127,
not 1, if the decompression process fails; this is more compatible
with meta-programs like nohup.  Have the executable
uncompress to a temp file with the same basename as the executable;
this is more likely to go right.  Fix a race condition where the
executable temporarily did not exist (in either old or new forms).
Check for race conditions better when mv fails.  Do not attempt
to use cp to do the real work, only to copy permissions to a temp
file, since we don't want to trash running executables.
ChangeLog
Makefile.am
NEWS
configure.ac
gzexe.in