Skip to content

Commit bda36af

Browse files
committed
FIX: warning: incompatible pointer types assigning
1 parent be4656b commit bda36af

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

src/core/u-lzw.c

+2-2
Original file line numberDiff line numberDiff line change
@@ -204,7 +204,7 @@ int lzw_compress (void (*dst)(int,void*), void *dstctx, int (*src)(void*), void
204204
total_codes = 1 << maxbits;
205205

206206
mem = Make_Binary((total_codes * sizeof(encoder_entry_t)) - 1); // using -1, because Make_Binary adds 1!
207-
dictionary = BIN_HEAD(mem);
207+
dictionary = (encoder_entry_t *)BIN_HEAD(mem);
208208
max_available_entries = total_codes - FIRST_STRING - 1;
209209
max_available_code = total_codes - 2;
210210

@@ -400,7 +400,7 @@ int lzw_decompress (void (*dst)(int,void*), void *dstctx, int (*src)(void*), voi
400400

401401
mem = Make_Binary((total_codes * sizeof(decoder_entry_t)) + (total_codes - 256) + (total_codes / 8) - 1);
402402

403-
dictionary = BIN_HEAD(mem);
403+
dictionary = (decoder_entry_t *)BIN_HEAD(mem);
404404
reverse_buffer = BIN_SKIP(mem, (total_codes * sizeof(decoder_entry_t)));
405405
referenced = BIN_SKIP(mem, (total_codes * sizeof(decoder_entry_t)) + (total_codes - 256)); // bitfield indicating code is referenced at least once
406406

0 commit comments

Comments
 (0)