Closed transmissions11 closed 1 year ago
"For "a*b" on signed integer, there is a specific edge case, where "a == -1", and "b == min int256", where "-b" does not fit into the representation, and thus the multiplication should revert (overflow)" - @montyly
Credit to @milotruck and @magnetto90 for discovering this bug!
Ensure you completed all of the steps below before submitting your pull request:
forge snapshot
npm run lint
forge test
Pull requests with an incomplete checklist will be thrown out.
Description
"For "a*b" on signed integer, there is a specific edge case, where "a == -1", and "b == min int256", where "-b" does not fit into the representation, and thus the multiplication should revert (overflow)" - @montyly
Credit to @milotruck and @magnetto90 for discovering this bug!
Checklist
Ensure you completed all of the steps below before submitting your pull request:
forge snapshot
?npm run lint
?forge test
?Pull requests with an incomplete checklist will be thrown out.