gzip: fix bug with any upper case custom ('-S'-specified) suffix
authorJim Meyering <meyering@fb.com>
Sat, 28 Oct 2017 21:15:04 +0000 (14:15 -0700)
committerJim Meyering <meyering@fb.com>
Sun, 29 Oct 2017 14:00:55 +0000 (07:00 -0700)
commit621b71dc5a3e523d4663d9021a9bbcc29c19690d
treed28cc7187879fa3335a60b78a1e4dd226789f333
parent79f88bd1e54d6042fbe50c212f836920fa208e56
gzip: fix bug with any upper case custom ('-S'-specified) suffix

Any user-specified suffix with an upper case
letter would fail to match desired file.
* gzip.c (get_suffix): First, arrange to have only one return
point rather than two. Put a lower-cased (just-malloc'd) copy
of z_suffix in the suffix vector, and free it before returning.
* tests/upper-suffix: New file.
* tests/Makefile.am (TESTS): Add it.
* NEWS: Mention it.
Reported by meo@xenialab.it in https://bugs.gnu.org/29006
NEWS
gnulib
gzip.c
tests/Makefile.am
tests/upper-suffix [new file with mode: 0755]