aboutsummaryrefslogtreecommitdiff
path: root/src/simplewallet/simplewallet.cpp
diff options
context:
space:
mode:
authorRiccardo Spagni <ric@spagni.net>2016-04-02 12:02:07 +0900
committerRiccardo Spagni <ric@spagni.net>2016-04-02 12:02:07 +0900
commita38ad63f8f0c9941ea964519f8e9d25db5e594b2 (patch)
treefb6f5bf87c8c55dfd017bd567a4ddb19db59a033 /src/simplewallet/simplewallet.cpp
parentMerge pull request #766 (diff)
parentConvey tx verification failure reasons to the RPC client (diff)
downloadmonero-a38ad63f8f0c9941ea964519f8e9d25db5e594b2.tar.xz
Merge pull request #767
24b3e90 Convey tx verification failure reasons to the RPC client (moneromooo-monero)
Diffstat (limited to 'src/simplewallet/simplewallet.cpp')
-rw-r--r--src/simplewallet/simplewallet.cpp6
1 files changed, 6 insertions, 0 deletions
diff --git a/src/simplewallet/simplewallet.cpp b/src/simplewallet/simplewallet.cpp
index 46e705673..d05b5ea4c 100644
--- a/src/simplewallet/simplewallet.cpp
+++ b/src/simplewallet/simplewallet.cpp
@@ -2201,6 +2201,9 @@ bool simple_wallet::transfer_main(bool new_algorithm, const std::vector<std::str
catch (const tools::error::tx_rejected& e)
{
fail_msg_writer() << (boost::format(tr("transaction %s was rejected by daemon with status: ")) % get_transaction_hash(e.tx())) << e.status();
+ std::string reason = e.reason();
+ if (!reason.empty())
+ fail_msg_writer() << tr("Reason: ") << reason;
}
catch (const tools::error::tx_sum_overflow& e)
{
@@ -2358,6 +2361,9 @@ bool simple_wallet::sweep_unmixable(const std::vector<std::string> &args_)
catch (const tools::error::tx_rejected& e)
{
fail_msg_writer() << (boost::format(tr("transaction %s was rejected by daemon with status: ")) % get_transaction_hash(e.tx())) << e.status();
+ std::string reason = e.reason();
+ if (!reason.empty())
+ fail_msg_writer() << tr("Reason: ") << reason;
}
catch (const tools::error::tx_sum_overflow& e)
{