- update to 1.12:
* 'gzip -l' no longer misreports file lengths 4 GiB and larger.
Previously, 'gzip -l' output the 32-bit value stored in the gzip
header even though that is the uncompressed length modulo 2**32.
Now, 'gzip -l' calculates the uncompressed length by decompressing
the data and counting the resulting bytes. Although this can take
much more time, nowadays the correctness pros seem to outweigh the
performance cons.
* 'zless' is no longer installed on platforms lacking 'less'.
* zgrep applied to a crafted file name with two or more newlines
can no longer overwrite an arbitrary, attacker-selected file.
[bug introduced in gzip-1.3.10]
* zgrep now names input file on error instead of mislabeling it as
"(standard input)", if grep supports the GNU -H and --label options.
* 'zdiff -C 5' no longer misbehaves by treating '5' as a file name.
* Configure-time options like --program-prefix now work.
- refresh zdiff.diff, zgrep.diff, zmore.diff
OBS-URL: https://build.opensuse.org/request/show/968007
OBS-URL: https://build.opensuse.org/package/show/Base:System/gzip?expand=0&rev=86
25 lines
621 B
Diff
25 lines
621 B
Diff
Index: zgrep.in
|
|
===================================================================
|
|
--- zgrep.in.orig
|
|
+++ zgrep.in
|
|
@@ -211,10 +211,18 @@ res=1
|
|
|
|
for i
|
|
do
|
|
+ case "$i" in
|
|
+ *.bz2)
|
|
+ uncompress=bzip2
|
|
+ ;;
|
|
+ *)
|
|
+ uncompress=gzip
|
|
+ ;;
|
|
+ esac
|
|
# Fail if gzip or grep (or sed) fails.
|
|
gzip_status=$(
|
|
exec 5>&1
|
|
- ('gzip' -cdfq -- "$i" 5>&-; echo $? >&5) 3>&- |
|
|
+ ($uncompress -cdfq -- "$i" 5>&-; echo $? >&5) 3>&- |
|
|
if test $files_with_matches -eq 1; then
|
|
eval "$grep$args" >/dev/null && { printf '%s\n' "$i" || exit 2; }
|
|
elif test $files_without_matches -eq 1; then
|