}
size_t decompressed_size = ZSTD_get_decompressed_size(input, input_size);
- if (decompressed_size == -1) {
+ if (decompressed_size == (size_t)-1) {
decompressed_size = MAX_COMPRESSION_RATIO * input_size;
fprintf(stderr, "WARNING: Compressed data does not contain "
"decompressed size, going to assume the compression "
free(dict);
input = output = dict = NULL;
}
-
// than the offset
// ex: if the output so far was "abc", a command with offset=3 and
// match_length=6 would produce "abcabcabc" as the new output
- for (size_t i = 0; i < match_length; i++) {
+ for (size_t j = 0; j < match_length; j++) {
*write_ptr = *(write_ptr - offset);
write_ptr++;
}
}
// Now we can fill baseline and num bits
- for (int i = 0; i < size; i++) {
+ for (size_t i = 0; i < size; i++) {
u8 symbol = dtable->symbols[i];
u16 next_state_desc = state_desc[symbol]++;
// Fills in the table appropriately, next_state_desc increases by symbol