rename write to wwrite to avoid variable shadowing.
This commit is contained in:
parent
8e71b08aa2
commit
8f50ba1350
|
@ -1,4 +1,4 @@
|
||||||
/* $NetBSD: inffast.c,v 1.1.1.1 2006/01/14 20:10:29 christos Exp $ */
|
/* $NetBSD: inffast.c,v 1.2 2006/01/14 20:26:05 christos Exp $ */
|
||||||
|
|
||||||
/* inffast.c -- fast decoding
|
/* inffast.c -- fast decoding
|
||||||
* Copyright (C) 1995-2004 Mark Adler
|
* Copyright (C) 1995-2004 Mark Adler
|
||||||
|
@ -81,7 +81,7 @@ unsigned start; /* inflate()'s starting value for strm->avail_out */
|
||||||
#endif
|
#endif
|
||||||
unsigned wsize; /* window size or zero if not using window */
|
unsigned wsize; /* window size or zero if not using window */
|
||||||
unsigned whave; /* valid bytes in the window */
|
unsigned whave; /* valid bytes in the window */
|
||||||
unsigned write; /* window write index */
|
unsigned wwrite; /* window write index */
|
||||||
unsigned char FAR *window; /* allocated sliding window, if wsize != 0 */
|
unsigned char FAR *window; /* allocated sliding window, if wsize != 0 */
|
||||||
unsigned long hold; /* local strm->hold */
|
unsigned long hold; /* local strm->hold */
|
||||||
unsigned bits; /* local strm->bits */
|
unsigned bits; /* local strm->bits */
|
||||||
|
@ -108,7 +108,7 @@ unsigned start; /* inflate()'s starting value for strm->avail_out */
|
||||||
#endif
|
#endif
|
||||||
wsize = state->wsize;
|
wsize = state->wsize;
|
||||||
whave = state->whave;
|
whave = state->whave;
|
||||||
write = state->write;
|
wwrite = state->write;
|
||||||
window = state->window;
|
window = state->window;
|
||||||
hold = state->hold;
|
hold = state->hold;
|
||||||
bits = state->bits;
|
bits = state->bits;
|
||||||
|
@ -194,7 +194,7 @@ unsigned start; /* inflate()'s starting value for strm->avail_out */
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
from = window - OFF;
|
from = window - OFF;
|
||||||
if (write == 0) { /* very common case */
|
if (wwrite == 0) { /* very common case */
|
||||||
from += wsize - op;
|
from += wsize - op;
|
||||||
if (op < len) { /* some from window */
|
if (op < len) { /* some from window */
|
||||||
len -= op;
|
len -= op;
|
||||||
|
@ -204,17 +204,17 @@ unsigned start; /* inflate()'s starting value for strm->avail_out */
|
||||||
from = out - dist; /* rest from output */
|
from = out - dist; /* rest from output */
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else if (write < op) { /* wrap around window */
|
else if (wwrite < op) { /* wrap around window */
|
||||||
from += wsize + write - op;
|
from += wsize + wwrite - op;
|
||||||
op -= write;
|
op -= wwrite;
|
||||||
if (op < len) { /* some from end of window */
|
if (op < len) { /* some from end of window */
|
||||||
len -= op;
|
len -= op;
|
||||||
do {
|
do {
|
||||||
PUP(out) = PUP(from);
|
PUP(out) = PUP(from);
|
||||||
} while (--op);
|
} while (--op);
|
||||||
from = window - OFF;
|
from = window - OFF;
|
||||||
if (write < len) { /* some from start of window */
|
if (wwrite < len) { /* some from start of window */
|
||||||
op = write;
|
op = wwrite;
|
||||||
len -= op;
|
len -= op;
|
||||||
do {
|
do {
|
||||||
PUP(out) = PUP(from);
|
PUP(out) = PUP(from);
|
||||||
|
@ -224,7 +224,7 @@ unsigned start; /* inflate()'s starting value for strm->avail_out */
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
else { /* contiguous in window */
|
else { /* contiguous in window */
|
||||||
from += write - op;
|
from += wwrite - op;
|
||||||
if (op < len) { /* some from window */
|
if (op < len) { /* some from window */
|
||||||
len -= op;
|
len -= op;
|
||||||
do {
|
do {
|
||||||
|
|
Loading…
Reference in New Issue