Skip to content

Commit

Permalink
allow NTCP2 only transports
Browse files Browse the repository at this point in the history
  • Loading branch information
orignal committed Aug 10, 2018
1 parent ee700ac commit a2c41c9
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 2 deletions.
5 changes: 3 additions & 2 deletions daemon/Daemon.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -289,9 +289,10 @@ namespace i2p
if(!ntcp) LogPrint(eLogInfo, "Daemon: ntcp disabled");

i2p::transport::transports.Start(ntcp, ssu);
if (i2p::transport::transports.IsBoundNTCP() || i2p::transport::transports.IsBoundSSU()) {
if (i2p::transport::transports.IsBoundNTCP() || i2p::transport::transports.IsBoundSSU() || i2p::transport::transports.IsBoundNTCP2())
LogPrint(eLogInfo, "Daemon: Transports started");
} else {
else
{
LogPrint(eLogError, "Daemon: failed to start Transports");
/** shut down netdb right away */
i2p::transport::transports.Stop();
Expand Down
1 change: 1 addition & 0 deletions libi2pd/Transports.h
Original file line number Diff line number Diff line change
Expand Up @@ -81,6 +81,7 @@ namespace transport

bool IsBoundNTCP() const { return m_NTCPServer != nullptr; }
bool IsBoundSSU() const { return m_SSUServer != nullptr; }
bool IsBoundNTCP2() const { return m_NTCP2Server != nullptr; }

bool IsOnline() const { return m_IsOnline; };
void SetOnline (bool online) { m_IsOnline = online; };
Expand Down

0 comments on commit a2c41c9

Please sign in to comment.