If the zlib-wrapped data to Inflate has, in its zlib header, CINFO
(which determines the LZ77 window size) that is other than 7 (the maximum valid), is it okay to Inflate it with the windowBits
of 15 (usually the value of MAX_WBITS
)?
I ask this question as everyone seems to do so and not care about the CINFO
.
Did I misunderstood something?
Yes, that's okay. The windowBits needs to be greater than or equal to the window size that the data was compressed with. It is always ok to decompress with the maximum window size (15).