The commit above primarily added a modified version of _adjustReservesForSwap to use when conducting arbitrage prevent reverts with zero SALT/WETH liquidity. its called adjustReservesForSwapNoRevert. Please note that this function has been subsequently deprecated and replaced with similar logic as so:
// Only swap for SALT with sufficient reserves
if ( ( reserves.reserve0 > PoolUtils.DUST ) && ( reserves.reserve1 > PoolUtils.DUST ) )
{
uint256 saltOut = _adjustReservesForSwap(reserves, flipped, arbitrageProfit);
essentially now the adjustments checks beforehand if reserves are sufficient to avoid the revert. the relevant commit for this change is :
Please note that the Utils.sol helper function was also modified as part of this commit, it primarily provides efficiency functions called from the Web3 UI.
Lines of code
Vulnerability details
Additional Scope Issue
https://github.com/othernet-global/salty-io/commit/6998661013e86a50c7db552d189fadb0521dbeb0
Comments
The commit above primarily added a modified version of _adjustReservesForSwap to use when conducting arbitrage prevent reverts with zero SALT/WETH liquidity. its called adjustReservesForSwapNoRevert. Please note that this function has been subsequently deprecated and replaced with similar logic as so:
essentially now the adjustments checks beforehand if reserves are sufficient to avoid the revert. the relevant commit for this change is :
https://github.com/othernet-global/salty-io/commit/75901cae57382a87b5f049d7afb9c5d9b9ba4c19
Please note that the Utils.sol helper function was also modified as part of this commit, it primarily provides efficiency functions called from the Web3 UI.
Conclusion
LGTM