PoolTogether Aave v3 contest - slywaters's results

A protocol for no loss prize savings on Ethereum.

General Information

Platform: Code4rena

Start Date: 29/04/2022

Pot Size: $22,000 USDC

Total HM: 6

Participants: 40

Period: 3 days

Judge: Justin Goro

Total Solo HM: 2

Id: 114

League: ETH

PoolTogether

Findings Distribution

Researcher Performance

Rank: 40/40

Findings: 1

Award: $27.86

🌟 Selected for report: 0

🚀 Solo Findings: 0

Awards

27.8625 USDC - $27.86

Labels

bug
G (Gas Optimization)

External Links

Gas Report

Replace strict greater-than-zero operation (> 0) with does-not-equal-zero (!= 0) operation

When checking whether a value is equal to zero, using the construction var != 0 is costs less gas than using var > 0. Note that this is true only when the comparison occurs in a conditional context and the Solidity compiler is using the Optimizer.

For more information, please consult the following resources:

Twitter discussion detailing the gas costs of != 0 vs > 0 in require() calls

Solidity Compiler: Optimizer options

The following lines of code are affected:

code4rena/pooltogether/AaveV3YieldSource.sol:179: require(decimals_ > 0, "AaveV3YS/decimals-gt-zero"); code4rena/pooltogether/AaveV3YieldSource.sol:233: require(_shares > 0, "AaveV3YS/shares-gt-zero");

#0 - PierrickGT

2022-05-02T23:54:14Z

AuditHub

A portfolio for auditors, a security profile for protocols, a hub for web3 security.

Built bymalatrax © 2024

Auditors

Browse

Contests

Browse

Get in touch

ContactTwitter