From df118e7c8ff255a3fa3ecf4d14b6e0b8ba9fff62 Mon Sep 17 00:00:00 2001 From: blackjok3r Date: Sun, 7 Apr 2019 23:16:25 +0800 Subject: [PATCH] fix json output --- src/txdb.cpp | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/src/txdb.cpp b/src/txdb.cpp index c8721c92a..e5c260e4f 100644 --- a/src/txdb.cpp +++ b/src/txdb.cpp @@ -548,7 +548,7 @@ int32_t CBlockTreeDB::Snapshot2(int64_t dustthreshold, int32_t top, bool fRPC ,s if ( fRPC ) { // Total amount in this snapshot, which is less than circulating supply if top parameter is used - ret.push_back(make_pair("total", (double) total / COIN )); + ret.push_back(make_pair("total", (double) (total+cryptoConditionsTotals)/ COIN )); // Average amount in each address of this snapshot ret.push_back(make_pair("average",(double) (total/COIN) / totalAddresses )); // Total number of utxos processed in this snaphot @@ -561,6 +561,8 @@ int32_t CBlockTreeDB::Snapshot2(int64_t dustthreshold, int32_t top, bool fRPC ,s ret.push_back(make_pair("skipped_cc_utxos", cryptoConditionsUTXOs)); // Total value of skipped crypto condition utxos ret.push_back(make_pair("cc_utxo_value", (double) cryptoConditionsTotals / COIN)); + // total of all the address's, does not count coins in CC vouts. + ret.push_back(make_pair("address_total", (double) total/ COIN )); // The snapshot finished at this block height ret.push_back(make_pair("ending_height", chainActive.Height())); }