From 03635f4444d7a02505d363ab588fb33e4ec4786b Mon Sep 17 00:00:00 2001 From: orignal Date: Sun, 26 May 2024 10:55:19 -0400 Subject: [PATCH] publish through tunnels in case of restricted routes --- libi2pd/RouterContext.cpp | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) diff --git a/libi2pd/RouterContext.cpp b/libi2pd/RouterContext.cpp index 4869ec32..8a6a21a5 100644 --- a/libi2pd/RouterContext.cpp +++ b/libi2pd/RouterContext.cpp @@ -1384,8 +1384,9 @@ namespace i2p if (m_Service) m_Service->GetService ().post ([this]() { HandlePublishResendTimer (boost::system::error_code ()); }); }; - if (floodfill->IsReachableFrom (i2p::context.GetRouterInfo ()) || // are we able to connect? - i2p::transport::transports.IsConnected (floodfill->GetIdentHash ())) // already connected ? + if (i2p::transport::transports.IsConnected (floodfill->GetIdentHash ()) || // already connected + (floodfill->IsReachableFrom (i2p::context.GetRouterInfo ()) && // are we able to connect + !i2p::transport::transports.RoutesRestricted ())) // and routes not restricted { // send directly auto msg = CreateDatabaseStoreMsg (i2p::context.GetSharedRouterInfo (), replyToken);