You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Failed system transfers (due to insufficient funds) charges a transaction fee on the payer account. And even if solana-cli can check whether the tx will fail or not because of that in advance, it naive submits the transfer transaction naively.
This is a bit unhelpful. Small, but it causes spending a tx fee and looks silly from the user's viewpoint.
For example, user must again manually calculate the reduced all remaining fund when doing manually this unimplemented thing: #9862
Proposed Solution
Fail by deafult by doing account's fund balance check and introduce --force? But then this will introduce false-positives due to toctou vulnerability. Maybe #8971 is the ultimate fix?
mvines
changed the title
solana-cli pay subcommand naively tries to pay even if unfunded
solana-cli transfer subcommand naively tries to pay even if unfunded
May 6, 2020
Problem
Failed system transfers (due to insufficient funds) charges a transaction fee on the payer account. And even if
solana-cli
can check whether the tx will fail or not because of that in advance, it naive submits the transfer transaction naively.This is a bit unhelpful. Small, but it causes spending a tx fee and looks silly from the user's viewpoint.
For example, user must again manually calculate the reduced all remaining fund when doing manually this unimplemented thing: #9862
Proposed Solution
Fail by deafult by doing account's fund balance check and introduce
--force
? But then this will introduce false-positives due to toctou vulnerability. Maybe #8971 is the ultimate fix?context
https://discord.com/channels/428295358100013066/439194979856809985/707339402250158210
The text was updated successfully, but these errors were encountered: