X-Git-Url: https://git.novaco.in/?a=blobdiff_plain;f=src%2Frpcwallet.cpp;h=ef9276c07f04a9f2320f747ab361fb7fc35cb5a7;hb=1fa736ae3426a7aa7dfc97322d33e4d5c99e4111;hp=d9662457e2d00779e537fb7a0ec779af1e541d24;hpb=4a948d93bd20158db7fb9f329221eeea7350f361;p=novacoin.git diff --git a/src/rpcwallet.cpp b/src/rpcwallet.cpp index d966245..ef9276c 100644 --- a/src/rpcwallet.cpp +++ b/src/rpcwallet.cpp @@ -88,8 +88,8 @@ Value getinfo(const Array& params, bool fHelp) auto nNtpOffset = GetNtpOffset(), nP2POffset = GetNodesOffset(); - timestamping.push_back(Pair("ntpoffset", nNtpOffset != INT64_MAX ? nNtpOffset : Value::null)); - timestamping.push_back(Pair("p2poffset", nP2POffset != INT64_MAX ? nP2POffset : Value::null)); + timestamping.push_back(Pair("ntpoffset", nNtpOffset != numeric_limits::max() ? nNtpOffset : Value::null)); + timestamping.push_back(Pair("p2poffset", nP2POffset != numeric_limits::max() ? nP2POffset : Value::null)); obj.push_back(Pair("timestamping", timestamping)); @@ -790,7 +790,7 @@ Value sendmany(const Array& params, bool fHelp) totalAmount += nAmount; - vecSend.push_back(make_pair(scriptPubKey, nAmount)); + vecSend.push_back({ scriptPubKey, nAmount }); } EnsureWalletIsUnlocked(); @@ -1754,7 +1754,7 @@ Value validateaddress(const Array& params, bool fHelp) auto currentAddress = address.ToString(); auto dest = address.Get(); ret.push_back(Pair("address", currentAddress)); - auto mine = pwalletMain ? IsMine(*pwalletMain, address) : MINE_NO; + auto mine = IsMine(*pwalletMain, address); ret.push_back(Pair("ismine", mine != MINE_NO)); if (mine != MINE_NO) { ret.push_back(Pair("watchonly", mine == MINE_WATCH_ONLY));