aboutsummaryrefslogtreecommitdiff
path: root/src/chainparamsbase.h
diff options
context:
space:
mode:
authorHennadii Stepanov <32963518+hebasto@users.noreply.github.com>2020-09-24 21:16:03 +0300
committerHennadii Stepanov <32963518+hebasto@users.noreply.github.com>2020-09-29 09:59:52 +0300
commitfdd3ae4d264f26f87009879838dec035db5a7aed (patch)
tree74ba7e28cf7e6ede89f97940d24ff536c0df3733 /src/chainparamsbase.h
parenta5266d4546c444cfd6d36cb63d2df52ce9e689e2 (diff)
net, refactor: Refactor CBaseChainParams::RPCPort function
Diffstat (limited to 'src/chainparamsbase.h')
-rw-r--r--src/chainparamsbase.h8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/chainparamsbase.h b/src/chainparamsbase.h
index f34df4bfdc..9b4ae2f7ab 100644
--- a/src/chainparamsbase.h
+++ b/src/chainparamsbase.h
@@ -26,15 +26,15 @@ public:
///@}
const std::string& DataDir() const { return strDataDir; }
- int RPCPort() const { return nRPCPort; }
+ uint16_t RPCPort() const { return m_rpc_port; }
uint16_t OnionServiceTargetPort() const { return m_onion_service_target_port; }
CBaseChainParams() = delete;
- CBaseChainParams(const std::string& data_dir, int rpc_port, uint16_t onion_service_target_port)
- : nRPCPort(rpc_port), m_onion_service_target_port(onion_service_target_port), strDataDir(data_dir) {}
+ CBaseChainParams(const std::string& data_dir, uint16_t rpc_port, uint16_t onion_service_target_port)
+ : m_rpc_port(rpc_port), m_onion_service_target_port(onion_service_target_port), strDataDir(data_dir) {}
private:
- int nRPCPort;
+ const uint16_t m_rpc_port;
const uint16_t m_onion_service_target_port;
std::string strDataDir;
};