mirror of
https://github.com/g4klx/MMDVMHost.git
synced 2026-04-07 07:23:53 +00:00
add IPv6 support for RemoteControl
To specify IP(v4/v6) address for RemoteControl port, add Address parameter in [RemoteControl] section to MMDVM.ini. Different from other Address(es), the default IP address of RemoteControl is 127.0.0.1 for security.
This commit is contained in:
parent
88bbb0cd0f
commit
5df1fe551f
6 changed files with 18 additions and 5 deletions
|
|
@ -29,8 +29,8 @@ const unsigned int PAGE_ARGS = 3U;
|
|||
|
||||
const unsigned int BUFFER_LENGTH = 100U;
|
||||
|
||||
CRemoteControl::CRemoteControl(unsigned int port) :
|
||||
m_socket(port),
|
||||
CRemoteControl::CRemoteControl(const std::string address, unsigned int port) :
|
||||
m_socket(address, port),
|
||||
m_command(RCD_NONE),
|
||||
m_args()
|
||||
{
|
||||
|
|
@ -43,7 +43,7 @@ CRemoteControl::~CRemoteControl()
|
|||
|
||||
bool CRemoteControl::open()
|
||||
{
|
||||
return m_socket.open(AF_INET); /* XXX IPv4 only */
|
||||
return m_socket.open();
|
||||
}
|
||||
|
||||
REMOTE_COMMAND CRemoteControl::getCommand()
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue