code-423n4 / 2022-03-sublime-findings

0 stars 0 forks source link

QA Report #52

Closed code423n4 closed 2 years ago

code423n4 commented 2 years ago

M-02:

LenderPool.terminate(uint256,address) (PooledCreditLine/LenderPool.sol#394-409) deletes LenderPool.LenderPoolVariables (PooledCreditLine/LenderPool.sol#100-107) which contains a mapping:

        -delete pooledCLVariables[_id] (PooledCreditLine/LenderPool.sol#408)

Reference: https://github.com/crytic/slither/wiki/Detector-Documentation#deletion-on-mapping-containing-a-structure

ritik99 commented 2 years ago

This is expected - we cannot iterate over the lender's mapping and delete it. Since this data is stored per id, there is no risk of reusing a mapping as well