From 8686f6467c9db2606706baca33842c97ff7621f8 Mon Sep 17 00:00:00 2001 From: Peter Todd Date: Fri, 11 Jan 2013 06:11:34 -0500 Subject: Add timeoffset to getinfo RPC call Provides a method to get the difference between network adjusted time and local time from the RPC interface. --- src/rpcwallet.cpp | 1 + 1 file changed, 1 insertion(+) (limited to 'src/rpcwallet.cpp') diff --git a/src/rpcwallet.cpp b/src/rpcwallet.cpp index 90a68f560..21eb2fd1a 100644 --- a/src/rpcwallet.cpp +++ b/src/rpcwallet.cpp @@ -75,6 +75,7 @@ Value getinfo(const Array& params, bool fHelp) obj.push_back(Pair("walletversion", pwalletMain->GetVersion())); obj.push_back(Pair("balance", ValueFromAmount(pwalletMain->GetBalance()))); obj.push_back(Pair("blocks", (int)nBestHeight)); + obj.push_back(Pair("timeoffset", (boost::int64_t)GetTimeOffset())); obj.push_back(Pair("connections", (int)vNodes.size())); obj.push_back(Pair("proxy", (proxy.first.IsValid() ? proxy.first.ToStringIPPort() : string()))); obj.push_back(Pair("difficulty", (double)GetDifficulty())); -- cgit v1.2.3