The contract Swap uses OpenZeppelin's SafeMath library to avoid overflows and underflows in math calculations, although Solidity 0.8.0 and higher versions has built-in checks for overflows and underflows in math operations.
Impact
The use of SafeMath adds overhead and increase gas usage.
Handle
pants
Vulnerability details
The contract
Swap
uses OpenZeppelin'sSafeMath
library to avoid overflows and underflows in math calculations, although Solidity 0.8.0 and higher versions has built-in checks for overflows and underflows in math operations.Impact
The use of
SafeMath
adds overhead and increase gas usage.Tool Used
Manual code review.
Recommended Mitigation Steps
Don't use this library in
Swap
.