From: Jim Meyering Date: Wed, 29 Jul 2015 05:31:30 +0000 (-0700) Subject: maint: remove dead code X-Git-Tag: v1.7~30 X-Git-Url: https://git.gag.com/?a=commitdiff_plain;h=0f0c6c12169dd2bcb05909e20e10f94a1c54d69f;p=debian%2Fgzip maint: remove dead code This package has not been compilable with -DCRYPT since commit v1.4-82-g9d1b943. Remove final vestiges. * bits.c (copy_block) [CRYPT]: Remove #ifdef'd code. * inflate.c (NEXTBYTE) [CRYPT]: Likewise. Prompted by a report from Flávio Medeiros that HEADER and T might be used uninitialized. --- diff --git a/bits.c b/bits.c index 03ea3e9..a6dc4de 100644 --- a/bits.c +++ b/bits.c @@ -205,10 +205,6 @@ void copy_block(buf, len, header) bits_sent += (off_t)len<<3; #endif while (len--) { -#ifdef CRYPT - int t; - if (key) zencode(*buf, t); -#endif put_byte(*buf++); } } diff --git a/inflate.c b/inflate.c index 14bdfc0..c81879f 100644 --- a/inflate.c +++ b/inflate.c @@ -219,13 +219,7 @@ static ush mask_bits[] = { #define GETBYTE() (inptr < insize ? inbuf[inptr++] : (wp = w, fill_inbuf(0))) -#ifdef CRYPT - uch cc; -# define NEXTBYTE() \ - (decrypt ? (cc = GETBYTE(), zdecode(cc), cc) : GETBYTE()) -#else -# define NEXTBYTE() (uch)GETBYTE() -#endif +#define NEXTBYTE() (uch)GETBYTE() #define NEEDBITS(n) {while(k<(n)){b|=((ulg)NEXTBYTE())<>=(n);k-=(n);}