Open kba-3e opened 5 years ago
The Simple8 RLE decompression gives wrong values, for some inputs. In particular, when expanding a RLE compressed value, with significand bit set to 1, it will return a negative value. For example: {0xF0000000L, 0xF0000000L, 0xF0000000L}
{0xF0000000L, 0xF0000000L, 0xF0000000L}
The offending line is https://github.com/burmanm/compression-int/blob/cb30ac0670cf43d094b8bb9961f2ec7ad19e130f/src/main/java/fi/iki/yak/compression/integer/Simple8RLE.java#L312
Which should be:
long value = input[inputPos] & 0xFFFFFFFFL; // Last 32 bits only
The Simple8 RLE decompression gives wrong values, for some inputs. In particular, when expanding a RLE compressed value, with significand bit set to 1, it will return a negative value. For example:
{0xF0000000L, 0xF0000000L, 0xF0000000L}
The offending line is https://github.com/burmanm/compression-int/blob/cb30ac0670cf43d094b8bb9961f2ec7ad19e130f/src/main/java/fi/iki/yak/compression/integer/Simple8RLE.java#L312
Which should be: