Skip to content

Latest commit

 

History

History
5 lines (3 loc) · 571 Bytes

File metadata and controls

5 lines (3 loc) · 571 Bytes

Suspicious gas cost estimate in _payoutEth() function of PA1D contract

Gas cost is calculated as (23300 * length) + length, possibly to account for a base cost of 21000 and the transfer which is limited to 2300 (21000+2300=23300), but this estimate is just gas units, the estimation should multiply it by the gas price.

Also, the gas cost of transferring the ETH should be covered by the account that originated the transaction, but in the code the gas cost is subtracted from the balance to be distributed. In any case, it should be refunded to the caller.