mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-02-24 04:37:37 +01:00
Merge pull request #1 from vmon/f--port-0-for-TCPAcceptor
the change allows when an TCPIPAcceptor is constructed by setting por…
This commit is contained in:
commit
85ddb31dbe
1 changed files with 2 additions and 0 deletions
|
@ -280,6 +280,8 @@ namespace client
|
||||||
void TCPIPAcceptor::Start ()
|
void TCPIPAcceptor::Start ()
|
||||||
{
|
{
|
||||||
m_Acceptor.reset (new boost::asio::ip::tcp::acceptor (GetService (), m_LocalEndpoint));
|
m_Acceptor.reset (new boost::asio::ip::tcp::acceptor (GetService (), m_LocalEndpoint));
|
||||||
|
//update the local end point in case port has been set zero and got updated now
|
||||||
|
m_LocalEndpoint = m_Acceptor->local_endpoint();
|
||||||
m_Acceptor->listen ();
|
m_Acceptor->listen ();
|
||||||
Accept ();
|
Accept ();
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue