From bf8a04a165e1c19dffce70a7e5c3fb10b0035d96 Mon Sep 17 00:00:00 2001 From: Luke Dashjr Date: Tue, 25 Oct 2016 08:04:23 +0000 Subject: Reformat touched lines with C++11 --- src/rpc/misc.cpp | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) (limited to 'src/rpc/misc.cpp') diff --git a/src/rpc/misc.cpp b/src/rpc/misc.cpp index 746189a2ae..fe46f61d81 100644 --- a/src/rpc/misc.cpp +++ b/src/rpc/misc.cpp @@ -101,8 +101,9 @@ UniValue getinfo(const JSONRPCRequest& request) obj.push_back(Pair("keypoololdest", pwallet->GetOldestKeyPoolTime())); obj.push_back(Pair("keypoolsize", (int)pwallet->GetKeyPoolSize())); } - if (pwallet && pwallet->IsCrypted()) + if (pwallet && pwallet->IsCrypted()) { obj.push_back(Pair("unlocked_until", pwallet->nRelockTime)); + } obj.push_back(Pair("paytxfee", ValueFromAmount(payTxFee.GetFeePerK()))); #endif obj.push_back(Pair("relayfee", ValueFromAmount(::minRelayTxFee.GetFeePerK()))); @@ -210,8 +211,9 @@ UniValue validateaddress(const JSONRPCRequest& request) ret.push_back(Pair("iswatchonly", (mine & ISMINE_WATCH_ONLY) ? true: false)); UniValue detail = boost::apply_visitor(DescribeAddressVisitor(pwallet), dest); ret.pushKVs(detail); - if (pwallet && pwallet->mapAddressBook.count(dest)) + if (pwallet && pwallet->mapAddressBook.count(dest)) { ret.push_back(Pair("account", pwallet->mapAddressBook[dest].name)); + } CKeyID keyID; if (pwallet) { const auto& meta = pwallet->mapKeyMetadata; @@ -257,16 +259,16 @@ CScript _createmultisig_redeemScript(CWallet * const pwallet, const UniValue& pa #ifdef ENABLE_WALLET // Case 1: Bitcoin address and we have full public key: CBitcoinAddress address(ks); - if (pwallet && address.IsValid()) - { + if (pwallet && address.IsValid()) { CKeyID keyID; if (!address.GetKeyID(keyID)) throw runtime_error( strprintf("%s does not refer to a key",ks)); CPubKey vchPubKey; - if (!pwallet->GetPubKey(keyID, vchPubKey)) + if (!pwallet->GetPubKey(keyID, vchPubKey)) { throw runtime_error( strprintf("no full public key for address %s",ks)); + } if (!vchPubKey.IsFullyValid()) throw runtime_error(" Invalid public key: "+ks); pubkeys[i] = vchPubKey; -- cgit v1.2.3