aboutsummaryrefslogtreecommitdiff
path: root/src/net.h
diff options
context:
space:
mode:
authorWladimir J. van der Laan <laanwj@gmail.com>2014-05-05 13:22:28 +0200
committerWladimir J. van der Laan <laanwj@gmail.com>2014-05-06 09:34:54 +0200
commitd387b8ec15e553db9b9c370314ee359e981fb374 (patch)
tree9d1b3a161e60aff59f00ee0e9ad1fcc75ccd5056 /src/net.h
parentd4ffe4e425b5a3f6fe4ff0ce7297608dfe6c7417 (diff)
downloadbitcoin-d387b8ec15e553db9b9c370314ee359e981fb374.tar.xz
rpc: add `getblockchaininfo` and `getnetworkinfo`
Adds two new info query commands that take over information from hodge-podge `getinfo`. Also some new information is added: - `getblockchaininfo` - `chain`: (string) current chain (main, testnet3, regtest) - `verificationprogress: (numeric) estimated verification progress - `chainwork` - `getnetworkinfo` - `localaddresses`: (array) local addresses, from mapLocalHost (fixes #1734)
Diffstat (limited to 'src/net.h')
-rw-r--r--src/net.h7
1 files changed, 7 insertions, 0 deletions
diff --git a/src/net.h b/src/net.h
index 6210ed80c1..729b1bcd57 100644
--- a/src/net.h
+++ b/src/net.h
@@ -116,6 +116,13 @@ extern CCriticalSection cs_vAddedNodes;
extern NodeId nLastNodeId;
extern CCriticalSection cs_nLastNodeId;
+struct LocalServiceInfo {
+ int nScore;
+ int nPort;
+};
+
+extern CCriticalSection cs_mapLocalHost;
+extern map<CNetAddr, LocalServiceInfo> mapLocalHost;
class CNodeStats
{