Regularise the local address handling across all of the protocol.

This commit is contained in:
Jonathan Naylor
2021-04-25 11:10:35 +01:00
parent 8b45e04ea0
commit 7008c624d9
22 changed files with 158 additions and 96 deletions

View File

@@ -31,7 +31,7 @@ const unsigned int BUFFER_LENGTH = 500U;
const unsigned int HOMEBREW_DATA_PACKET_LENGTH = 55U;
CDMRGatewayNetwork::CDMRGatewayNetwork(const std::string& address, unsigned short port, unsigned short local, unsigned int id, bool duplex, const char* version, bool slot1, bool slot2, HW_TYPE hwType, bool debug) :
CDMRGatewayNetwork::CDMRGatewayNetwork(const std::string& address, unsigned short port, const std::string& localAddress, unsigned short localPort, unsigned int id, bool duplex, const char* version, bool slot1, bool slot2, HW_TYPE hwType, bool debug) :
m_addressStr(address),
m_addr(),
m_addrLen(0U),
@@ -40,7 +40,7 @@ m_id(NULL),
m_duplex(duplex),
m_version(version),
m_debug(debug),
m_socket(local),
m_socket(localAddress, localPort),
m_enabled(false),
m_slot1(slot1),
m_slot2(slot2),