diff options
author | luigi1111 <luigi1111w@gmail.com> | 2021-04-22 01:35:20 -0400 |
---|---|---|
committer | luigi1111 <luigi1111w@gmail.com> | 2021-04-22 01:35:20 -0400 |
commit | 9bba3f4767c32292cd616512cc492ca416f6adc1 (patch) | |
tree | ca626c29cda8a00891be0e0c78fd73eec161e73c /src/wallet/wallet_errors.h | |
parent | Merge pull request #7643 (diff) | |
parent | monero-wallet-cli: improve error message when tx amount is zero (diff) | |
download | monero-9bba3f4767c32292cd616512cc492ca416f6adc1.tar.xz |
Merge pull request #7651
c8ff1d4 monero-wallet-cli: improve error message when tx amount is zero (Elliot Wirrick)
Diffstat (limited to 'src/wallet/wallet_errors.h')
-rw-r--r-- | src/wallet/wallet_errors.h | 11 |
1 files changed, 10 insertions, 1 deletions
diff --git a/src/wallet/wallet_errors.h b/src/wallet/wallet_errors.h index 4a89ed81a..011780f43 100644 --- a/src/wallet/wallet_errors.h +++ b/src/wallet/wallet_errors.h @@ -83,6 +83,7 @@ namespace tools // tx_rejected // tx_sum_overflow // tx_too_big + // zero_amount // zero_destination // wallet_rpc_error * // daemon_busy @@ -750,10 +751,18 @@ namespace tools uint64_t m_tx_weight_limit; }; //---------------------------------------------------------------------------------------------------- + struct zero_amount: public transfer_error + { + explicit zero_amount(std::string&& loc) + : transfer_error(std::move(loc), "destination amount is zero") + { + } + }; + //---------------------------------------------------------------------------------------------------- struct zero_destination : public transfer_error { explicit zero_destination(std::string&& loc) - : transfer_error(std::move(loc), "destination amount is zero") + : transfer_error(std::move(loc), "transaction has no destination") { } }; |