Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Gas savings on uninitialized variables. #101

Open
code423n4 opened this issue Jun 23, 2021 · 1 comment
Open

Gas savings on uninitialized variables. #101

code423n4 opened this issue Jun 23, 2021 · 1 comment

Comments

@code423n4
Copy link
Contributor

Handle

tensors

Vulnerability details

##Impact
Uninitialized variables initialize to 0 automatically. No need to explicitly initialize it.

##Proof of concept
https://github.com/pooltogether/aave-yield-source/blob/bc65c875f62235b7af55ede92231a495ba091a47/contracts/yield-source/ATokenYieldSource.sol#L141

##Recommended mitigation steps
Replace with: uint256 shares;

@PierrickGT
Copy link
Member

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

3 participants