Platform: Code4rena
Start Date: 03/07/2023
Pot Size: $40,000 USDC
Total HM: 14
Participants: 74
Period: 7 days
Judge: alcueca
Total Solo HM: 9
Id: 259
League: ETH
Rank: 64/74
Findings: 1
Award: $7.89
🌟 Selected for report: 0
🚀 Solo Findings: 0
🌟 Selected for report: SM3_SS
Also found by: 0x11singh99, 0xAnah, 0xSmartContract, 0xn006e7, 0xprinc, DavidGiladi, ElCid, JCN, K42, MIQUINHO, Raihan, Rolezn, SAAJ, SY_S, Strausses, TheSavageTeddy, bigtone, erebus, hunter_w3b, josephdara, lsaudit, mahdirostami, oakcobalt, peanuts, pfapostol, seth_lawson
7.8853 USDC - $7.89
Do While
of instead for
in some functionsUsing do while
instead of for
in some functions may save some gas
for(uint256 i;i < _tokens.length;++i;) { reserves[i] = _tokens[i].balanceOf(address(this)); }
uint256 i; do { reserves[i] = _tokens[i].balanceOf(address(this)); unchecked { ++i; } } while(i < _tokens.length);
https://github.com/code-423n4/2023-07-basin/blob/c1b72d4e372a6246e0efbd57b47fb4cbb5d77062/src/Well.sol#L382 https://github.com/code-423n4/2023-07-basin/blob/c1b72d4e372a6246e0efbd57b47fb4cbb5d77062/src/Well.sol#L452 https://github.com/code-423n4/2023-07-basin/blob/c1b72d4e372a6246e0efbd57b47fb4cbb5d77062/src/Well.sol#L593 https://github.com/code-423n4/2023-07-basin/blob/c1b72d4e372a6246e0efbd57b47fb4cbbd77062/src/Well.sol#L632 https://github.com/code-423n4/2023-07-basin/blob/c1b72d4e372a6246e0efbd57b47fb4cbb5d77062/src/Well.sol#L760
#0 - c4-pre-sort
2023-07-12T09:59:38Z
141345 marked the issue as low quality report
#1 - c4-judge
2023-08-05T11:02:35Z
alcueca marked the issue as grade-c
#2 - c4-judge
2023-08-05T11:02:40Z
alcueca marked the issue as grade-b