summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--deflate.c4
-rw-r--r--deflate_p.h10
-rw-r--r--deflate_slow.c6
-rw-r--r--infback.c2
4 files changed, 11 insertions, 11 deletions
diff --git a/deflate.c b/deflate.c
index 72da7e8..8bba945 100644
--- a/deflate.c
+++ b/deflate.c
@@ -163,7 +163,7 @@ static const config configuration_table[10] = {
static void slide_hash(deflate_state *s) {
unsigned n;
Pos *p;
- uInt wsize = s->w_size;
+ unsigned int wsize = s->w_size;
n = s->hash_size;
p = &s->head[n];
@@ -1347,7 +1347,7 @@ static block_state deflate_stored(deflate_state *s, int flush) {
/* maximum stored block length that will fit in avail_out: */
have = s->strm->avail_out - have;
left = s->strstart - s->block_start; /* bytes left in window */
- if (len > (ulg)left + s->strm->avail_in)
+ if (len > (unsigned long)left + s->strm->avail_in)
len = left + s->strm->avail_in; /* limit len to the input */
if (len > have)
len = have; /* limit len to the output */
diff --git a/deflate_p.h b/deflate_p.h
index 3550818..a446544 100644
--- a/deflate_p.h
+++ b/deflate_p.h
@@ -33,12 +33,12 @@ void flush_pending(z_stream *strm);
*/
#ifdef X86_SSE4_2_CRC_HASH
-extern Pos insert_string_sse(deflate_state *const s, const Pos str, uInt count);
+extern Pos insert_string_sse(deflate_state *const s, const Pos str, unsigned int count);
#endif
-static inline Pos insert_string_c(deflate_state *const s, const Pos str, uInt count) {
+static inline Pos insert_string_c(deflate_state *const s, const Pos str, unsigned int count) {
Pos ret = 0;
- uInt idx;
+ unsigned int idx;
for (idx = 0; idx < count; idx++) {
UPDATE_HASH(s, s->ins_h, str+idx);
@@ -51,7 +51,7 @@ static inline Pos insert_string_c(deflate_state *const s, const Pos str, uInt co
return ret;
}
-static inline Pos insert_string(deflate_state *const s, const Pos str, uInt count) {
+static inline Pos insert_string(deflate_state *const s, const Pos str, unsigned int count) {
#ifdef X86_SSE4_2_CRC_HASH
if (x86_cpu_has_sse42)
return insert_string_sse(s, str, count);
@@ -67,7 +67,7 @@ static inline Pos insert_string(deflate_state *const s, const Pos str, uInt coun
_tr_flush_block(s, (s->block_start >= 0L ? \
(char *)&s->window[(unsigned)s->block_start] : \
NULL), \
- (ulg)((long)s->strstart - s->block_start), \
+ (unsigned long)((long)s->strstart - s->block_start), \
(last)); \
s->block_start = s->strstart; \
flush_pending(s->strm); \
diff --git a/deflate_slow.c b/deflate_slow.c
index f9e81d5..c0be3ea 100644
--- a/deflate_slow.c
+++ b/deflate_slow.c
@@ -79,7 +79,7 @@ block_state deflate_slow(deflate_state *s, int flush) {
* match is not better, output the previous match:
*/
if (s->prev_length >= MIN_MATCH && s->match_length <= s->prev_length) {
- uInt max_insert = s->strstart + s->lookahead - MIN_MATCH;
+ unsigned int max_insert = s->strstart + s->lookahead - MIN_MATCH;
/* Do not insert strings in hash table beyond this. */
check_match(s, s->strstart-1, s->prev_match, s->prev_length);
@@ -105,8 +105,8 @@ block_state deflate_slow(deflate_state *s, int flush) {
s->strstart++;
#else
{
- uInt mov_fwd = s->prev_length - 2;
- uInt insert_cnt = mov_fwd;
+ unsigned int mov_fwd = s->prev_length - 2;
+ unsigned int insert_cnt = mov_fwd;
if (unlikely(insert_cnt > max_insert - s->strstart))
insert_cnt = max_insert - s->strstart;
diff --git a/infback.c b/infback.c
index 81f792e..5c545b4 100644
--- a/infback.c
+++ b/infback.c
@@ -46,7 +46,7 @@ int ZEXPORT inflateBackInit_(z_stream *strm, int windowBits, unsigned char *wind
Tracev((stderr, "inflate: allocated\n"));
strm->state = (struct internal_state *)state;
state->dmax = 32768U;
- state->wbits = (uInt)windowBits;
+ state->wbits = (unsigned int)windowBits;
state->wsize = 1U << windowBits;
state->window = window;
state->wnext = 0;