Skip to content

Commit

Permalink
don't set proxy if ntcp2 is disabled
Browse files Browse the repository at this point in the history
  • Loading branch information
orignal committed Mar 10, 2021
1 parent 3792bb4 commit 744b251
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 3 deletions.
2 changes: 1 addition & 1 deletion daemon/Daemon.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -367,7 +367,7 @@ namespace util
if(!ntcp2) LogPrint(eLogInfo, "Daemon: ntcp2 disabled");

i2p::transport::transports.SetCheckReserved(checkInReserved);
i2p::transport::transports.Start(ntcp2 || i2p::context.SupportsMesh (), ssu);
i2p::transport::transports.Start(ntcp2, ssu);
if (i2p::transport::transports.IsBoundSSU() || i2p::transport::transports.IsBoundNTCP2())
LogPrint(eLogInfo, "Daemon: Transports started");
else
Expand Down
4 changes: 2 additions & 2 deletions libi2pd/Transports.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -174,9 +174,9 @@ namespace transport
std::string ntcp2proxy; i2p::config::GetOption("ntcp2.proxy", ntcp2proxy);
i2p::http::URL proxyurl;
// create NTCP2. TODO: move to acceptor
if (enableNTCP2)
if (enableNTCP2 || i2p::context.SupportsMesh ())
{
if(!ntcp2proxy.empty())
if(!ntcp2proxy.empty() && enableNTCP2)
{
if(proxyurl.parse(ntcp2proxy))
{
Expand Down

0 comments on commit 744b251

Please sign in to comment.