X-Git-Url: https://git.novaco.in/?a=blobdiff_plain;f=src%2Fbitcoinrpc.cpp;h=63375fe5a5fbf1dde53fa4d2c020fbfef13eb20e;hb=4f6b3161b2dc18c9a3d4143d63fbbd0737296eb0;hp=50299cc88ce95713b9dd00f46a0a5b437584068f;hpb=a51c66c4d8df35570d1c401e4848e6fd0bdacdc8;p=novacoin.git diff --git a/src/bitcoinrpc.cpp b/src/bitcoinrpc.cpp index 50299cc..63375fe 100644 --- a/src/bitcoinrpc.cpp +++ b/src/bitcoinrpc.cpp @@ -159,6 +159,7 @@ Object blockToJSON(const CBlock& block, const CBlockIndex* blockindex, bool fPri if (fPrintTransactionDetail) { txinfo.push_back(tx.ToStringShort()); + txinfo.push_back(DateTimeStrFormat(tx.nTime)); BOOST_FOREACH(const CTxIn& txin, tx.vin) txinfo.push_back(txin.ToStringShort()); BOOST_FOREACH(const CTxOut& txout, tx.vout) @@ -287,6 +288,7 @@ Value getdifficulty(const Array& params, bool fHelp) Object obj; obj.push_back(Pair("proof-of-work", GetDifficulty())); obj.push_back(Pair("proof-of-stake", GetDifficulty(GetLastBlockIndex(pindexBest, true)))); + obj.push_back(Pair("search-interval", (int)nLastCoinStakeSearchInterval)); return obj; } @@ -2105,14 +2107,15 @@ Value checkwallet(const Array& params, bool fHelp) int nMismatchSpent; int64 nBalanceInQuestion; - if (!pwalletMain->CheckSpentCoins(nMismatchSpent, nBalanceInQuestion)) + Object result; + if (pwalletMain->CheckSpentCoins(nMismatchSpent, nBalanceInQuestion)) + result.push_back(Pair("wallet check passed", true)); + else { - Object result; result.push_back(Pair("mismatched spent coins", nMismatchSpent)); result.push_back(Pair("amount in question", ValueFromAmount(nBalanceInQuestion))); - return result; } - return Value::null; + return result; } @@ -2129,9 +2132,7 @@ Value repairwallet(const Array& params, bool fHelp) pwalletMain->FixSpentCoins(nMismatchSpent, nBalanceInQuestion); Object result; if (nMismatchSpent == 0) - { result.push_back(Pair("wallet check passed", true)); - } else { result.push_back(Pair("mismatched spent coins", nMismatchSpent));