Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
oss-fuzz 44160: Check available buffer space reading xref offsets
The code works out how much buffer it has left to safely use, but it was possible for a malformed file to cause that calculation to run into negative values, then used as an unsigned in parameter, meaning we potentially overflow the buffer. Change it so the parameter is a signed int, and check the value is positive before carrying on - error if it is not.
- Loading branch information