mirror of
https://github.com/monero-project/monero.git
synced 2026-01-01 15:36:08 -08:00
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.
This commit is contained in:
@@ -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;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user