diff options
author | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2015-10-28 18:08:14 +0000 |
---|---|---|
committer | moneromooo-monero <moneromooo-monero@users.noreply.github.com> | 2015-10-28 18:09:36 +0000 |
commit | 051ddbc741b1b703f5d58193ea770b13887d4e49 (patch) | |
tree | 0592af68b26102813ca855fe0a0cb38457b2df48 /src/rpc/core_rpc_server.cpp | |
parent | Merge pull request #453 (diff) | |
download | monero-051ddbc741b1b703f5d58193ea770b13887d4e49.tar.xz |
rpc: fix start_mining and status RPC crashes
They check whether they're running on testnet by accessing the
m_rpc_server object, which does not exist when in RPC mode.
Also, fix hard_fork_info being called with the wrong API.
Diffstat (limited to 'src/rpc/core_rpc_server.cpp')
-rw-r--r-- | src/rpc/core_rpc_server.cpp | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/src/rpc/core_rpc_server.cpp b/src/rpc/core_rpc_server.cpp index 6cfcec08c..f2a464c20 100644 --- a/src/rpc/core_rpc_server.cpp +++ b/src/rpc/core_rpc_server.cpp @@ -127,6 +127,7 @@ namespace cryptonote res.incoming_connections_count = total_conn - res.outgoing_connections_count; res.white_peerlist_size = m_p2p.get_peerlist_manager().get_white_peers_count(); res.grey_peerlist_size = m_p2p.get_peerlist_manager().get_gray_peers_count(); + res.testnet = m_testnet; res.status = CORE_RPC_STATUS_OK; return true; } |