sherlock-audit / 2024-02-jala-swap-judging

6 stars 4 forks source link

Lucyan99 - NC-1: Missing checks for `address(0)` when assigning values to address state variables #237

Closed sherlock-admin2 closed 7 months ago

sherlock-admin2 commented 7 months ago

Lucyan99

medium

NC-1: Missing checks for address(0) when assigning values to address state variables

Summary

Assigning values to address state variables without checking for address(0).

Code Snippet

Recommendation

Revert if the address is address(0).

nevillehuang commented 7 months ago

Invalid based on sherlock rules

  1. Zero address checks: Check to make sure input values are not zero addresses.