gzip/zmore.diff
Marcus Meissner 3489662bec Accepting request 968007 from home:dirkmueller:Factory
- 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
2022-04-09 12:42:32 +00:00

45 lines
856 B
Diff

---
zmore.in | 25 ++++++++++++++++++++++++-
1 file changed, 24 insertions(+), 1 deletion(-)
Index: gzip-1.12/zmore.in
===================================================================
--- gzip-1.12.orig/zmore.in
+++ gzip-1.12/zmore.in
@@ -38,6 +38,29 @@ case $1 in
exit 1;;
esac
+opt=
+pager ()
+{
+ eval ${PAGER-more} \$opt
+ cat > /dev/null
+}
+
+while :; do
+ case $1 in
+ --)
+ shift
+ break
+ ;;
+ [-+]*)
+ opt="$opt $1"
+ shift
+ ;;
+ *)
+ break
+ ;;
+ esac
+done
+
if test $# = 0; then
if test -t 0; then
printf >&2 '%s\n' "$0: missing operands; try '$0 --help' for help"
@@ -51,4 +74,4 @@ do
test $# -lt 2 ||
printf '::::::::::::::\n%s\n::::::::::::::\n' "$FILE" || break
'gzip' -cdfq -- "$FILE"
-done 2>&1 | eval ${PAGER-more}
+done 2>&1 | pager