kinow opened a new pull request #39: IMAGING-219: prevent infinite loop when decompressing RGBE input file URL: https://github.com/apache/commons-imaging/pull/39 The `decompress` method has an input stream. It compares if the value returned by `.read()` is greater than 128, otherwise tries to sum up a variable up to the value returned. However, the input stream may return `-1`, causing it to loop infinitely. This does not happen in Sanselan as there is no such format/parser doing any decompression with RGBE. Added an input file that fails, as well as a new unit test to confirm it is working. As the problem involves the code getting stuck, and we don't want the same to happen to our tests, by precaution added a timeout of 2 seconds in the test as well. Will merge in a few days if there is no objections here. Cheers Bruno
---------------------------------------------------------------- This is an automated message from the Apache Git Service. To respond to the message, please log on GitHub and use the URL above to go to the specific comment. For queries about this service, please contact Infrastructure at: [email protected] With regards, Apache Git Services --------------------------------------------------------------------- To unsubscribe, e-mail: [email protected] For additional commands, e-mail: [email protected]
