mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-04-28 11:47:48 +02:00
use uint16_t for ports
Signed-off-by: r4sas <r4sas@i2pmail.org>
This commit is contained in:
parent
3af1f4bc76
commit
03cc6e0524
17 changed files with 102 additions and 96 deletions
|
@ -1217,7 +1217,7 @@ namespace client
|
|||
subsessions.clear ();
|
||||
}
|
||||
|
||||
SAMSubSession::SAMSubSession (std::shared_ptr<SAMMasterSession> master, const std::string& name, SAMSessionType type, int port):
|
||||
SAMSubSession::SAMSubSession (std::shared_ptr<SAMMasterSession> master, const std::string& name, SAMSessionType type, uint16_t port):
|
||||
SAMSession (master->m_Bridge, name, type), masterSession (master), inPort (port)
|
||||
{
|
||||
if (Type == eSAMSessionTypeStream)
|
||||
|
@ -1244,7 +1244,7 @@ namespace client
|
|||
// TODO: implement datagrams
|
||||
}
|
||||
|
||||
SAMBridge::SAMBridge (const std::string& address, int portTCP, int portUDP, bool singleThread):
|
||||
SAMBridge::SAMBridge (const std::string& address, uint16_t portTCP, uint16_t portUDP, bool singleThread):
|
||||
RunnableService ("SAM"), m_IsSingleThread (singleThread),
|
||||
m_Acceptor (GetIOService (), boost::asio::ip::tcp::endpoint(boost::asio::ip::address::from_string(address), portTCP)),
|
||||
m_DatagramEndpoint (boost::asio::ip::address::from_string(address), (!portUDP) ? portTCP-1 : portUDP), m_DatagramSocket (GetIOService (), m_DatagramEndpoint),
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue