You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
launcherInfo.unlock is only initialised in finalize() which can be called only once. So the zero check before initializing it is unnecessary and wastes gas.
Handle
0xRajeev
Vulnerability details
Impact
launcherInfo.unlock is only initialised in finalize() which can be called only once. So the zero check before initializing it is unnecessary and wastes gas.
Proof of Concept
https://github.com/sushiswap/miso/blob/2cdb1486a55ded55c81898b7be8811cb68cfda9e/contracts/Liquidity/PostAuctionLauncher.sol#L87-L94
https://github.com/sushiswap/miso/blob/2cdb1486a55ded55c81898b7be8811cb68cfda9e/contracts/Liquidity/PostAuctionLauncher.sol#L260-L263
Tools Used
Manual Analysis
Recommended Mitigation Steps
Remove conditional and set it unconditionally.
The text was updated successfully, but these errors were encountered: