aboutsummaryrefslogtreecommitdiff
path: root/src/rpc/core_rpc_server.h
diff options
context:
space:
mode:
authordoy-lee <doylet@protonmail.com>2018-11-16 15:32:05 +1100
committerdoy-lee <doylet@protonmail.com>2018-11-16 15:32:05 +1100
commit6f2497bc7ac1865329527947afd6dacb0b1b6a06 (patch)
tree605f1a27ccba2d2ef738df809bbe4284f0246c27 /src/rpc/core_rpc_server.h
parentMerge pull request #4842 (diff)
downloadmonero-6f2497bc7ac1865329527947afd6dacb0b1b6a06.tar.xz
Don't cache nettype in core_rpc_server use m_core
This can go out of sync with m_core's nettype if you run in fakechain mode since entering fakechain mode is done through code not the command line and core_rpc_server only looks at the command line to figure out the nettype.
Diffstat (limited to 'src/rpc/core_rpc_server.h')
-rw-r--r--src/rpc/core_rpc_server.h3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/rpc/core_rpc_server.h b/src/rpc/core_rpc_server.h
index 3ba882b23..8f0d6112c 100644
--- a/src/rpc/core_rpc_server.h
+++ b/src/rpc/core_rpc_server.h
@@ -70,10 +70,9 @@ namespace cryptonote
bool init(
const boost::program_options::variables_map& vm,
const bool restricted,
- const network_type nettype,
const std::string& port
);
- network_type nettype() const { return m_nettype; }
+ network_type nettype() const { return m_core.get_nettype(); }
CHAIN_HTTP_TO_MAP2(connection_context); //forward http requests to uri map