From: Joel Rosdahl Date: Fri, 22 Jul 2016 13:36:20 +0000 (+0200) Subject: Avoid compilation warning in bundled zlib X-Git-Tag: v3.3~43 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=9052c3450ce5903ffc9fe3218fad27451416d3dc;p=thirdparty%2Fccache.git Avoid compilation warning in bundled zlib Applied upstream fix madler/zlib@e54e129. Closes #121. --- diff --git a/zlib/inflate.c b/zlib/inflate.c index 870f89bb4..4fd3f3c18 100644 --- a/zlib/inflate.c +++ b/zlib/inflate.c @@ -1504,9 +1504,10 @@ z_streamp strm; { struct inflate_state FAR *state; - if (strm == Z_NULL || strm->state == Z_NULL) return -1L << 16; + if (strm == Z_NULL || strm->state == Z_NULL) + return (long)(((unsigned long)0 - 1) << 16); state = (struct inflate_state FAR *)strm->state; - return ((long)(state->back) << 16) + + return (long)(((unsigned long)((long)state->back)) << 16) + (state->mode == COPY ? state->length : (state->mode == MATCH ? state->was - state->length : 0)); }