aboutsummaryrefslogtreecommitdiff
path: root/src/rpcwallet.cpp
diff options
context:
space:
mode:
authorAndrey <al42and@gmail.com>2012-12-16 23:10:32 +0400
committerAndrey <al42and@gmail.com>2012-12-16 23:10:32 +0400
commit1a20469428ef623f4edc2cdac72aef001836536c (patch)
treeb1b423d8ae5ce86d8acd043dc907a51a62b006dc /src/rpcwallet.cpp
parent62c9b1155f966cfb91d01d5598f974610962fa82 (diff)
downloadbitcoin-1a20469428ef623f4edc2cdac72aef001836536c.tar.xz
Updated help and tests for getreceivedby(account|address)
Diffstat (limited to 'src/rpcwallet.cpp')
-rw-r--r--src/rpcwallet.cpp10
1 files changed, 7 insertions, 3 deletions
diff --git a/src/rpcwallet.cpp b/src/rpcwallet.cpp
index e17be780ac..d9d364c820 100644
--- a/src/rpcwallet.cpp
+++ b/src/rpcwallet.cpp
@@ -892,9 +892,12 @@ Value ListReceived(const Array& params, bool fByAccounts)
obj.push_back(Pair("amount", ValueFromAmount(nAmount)));
obj.push_back(Pair("confirmations", (nConf == std::numeric_limits<int>::max() ? 0 : nConf)));
Array transactions;
- BOOST_FOREACH(const uint256& item, (*it).second.txids)
+ if (it != mapTally.end())
{
- transactions.push_back(item.GetHex());
+ BOOST_FOREACH(const uint256& item, (*it).second.txids)
+ {
+ transactions.push_back(item.GetHex());
+ }
}
obj.push_back(Pair("txids", transactions));
ret.push_back(obj);
@@ -929,7 +932,8 @@ Value listreceivedbyaddress(const Array& params, bool fHelp)
" \"address\" : receiving address\n"
" \"account\" : the account of the receiving address\n"
" \"amount\" : total amount received by the address\n"
- " \"confirmations\" : number of confirmations of the most recent transaction included");
+ " \"confirmations\" : number of confirmations of the most recent transaction included\n"
+ " \"txids\" : list of transactions with outputs to the address\n");
return ListReceived(params, false);
}