The exception handling in nextKeyValueTolerateCorruptions treats IOException as follows:
- if EOFException, corrupt, can be tolerated
- If CheckSumException, corrupt, can be tolerated
- else not a corruption, re-throw
But the compression code can also throw IOException in case of corruption, which will get re-thrown in this case.
The correct way of handling IOException is:
- if BlockMissingException, re-throw.
- if not BlockMissingException -> corruption, can be tolerated