Skip to content

Fix potential OOB read in localIjToCell#684

Merged
isaacbrodsky merged 1 commit intouber:masterfrom
isaacbrodsky:fix-localij-array-oob
Sep 12, 2022
Merged

Fix potential OOB read in localIjToCell#684
isaacbrodsky merged 1 commit intouber:masterfrom
isaacbrodsky:fix-localij-array-oob

Conversation

@isaacbrodsky
Copy link
Collaborator

Fixes a potential out-of-bounds read in localIjToCell that can occur with a particular combination of base cell, resolution, and highly negative IJ coordinates. The coordinates were only being tested against positive bounds, which was incorrect. As the function that compares to unit vectors handles this already, that check is replaced with that call.

@coveralls
Copy link

Coverage Status

Coverage decreased (-0.001%) to 99.034% when pulling 44d56b5 on isaacbrodsky:fix-localij-array-oob into f581626 on uber:master.

@isaacbrodsky isaacbrodsky merged commit fce1c53 into uber:master Sep 12, 2022
@isaacbrodsky isaacbrodsky deleted the fix-localij-array-oob branch September 12, 2022 23:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

4 participants