From 4abe89e34bec6dcba7eb2410c495d2e447b63b8d Mon Sep 17 00:00:00 2001 From: orignal Date: Sun, 31 Aug 2014 08:55:06 -0400 Subject: [PATCH] show expiring tunnel status --- HTTPServer.cpp | 10 ++++++++-- 1 file changed, 8 insertions(+), 2 deletions(-) diff --git a/HTTPServer.cpp b/HTTPServer.cpp index ece01e27..f2ce8c04 100644 --- a/HTTPServer.cpp +++ b/HTTPServer.cpp @@ -181,8 +181,11 @@ namespace util it->GetTunnelConfig ()->Print (s); if (it->GetTunnelPool () && !it->GetTunnelPool ()->IsExploratory ()) s << " " << "Pool"; - if (it->IsFailed ()) + auto state = it->GetState (); + if (state == i2p::tunnel::eTunnelStateFailed) s << " " << "Failed"; + else if (state == i2p::tunnel::eTunnelStateExpiring) + s << " " << "Exp"; s << " " << (int)it->GetNumSentBytes () << "
"; } @@ -191,8 +194,11 @@ namespace util it.second->GetTunnelConfig ()->Print (s); if (it.second->GetTunnelPool () && !it.second->GetTunnelPool ()->IsExploratory ()) s << " " << "Pool"; - if (it.second->IsFailed ()) + auto state = it.second->GetState (); + if (state == i2p::tunnel::eTunnelStateFailed) s << " " << "Failed"; + else if (state == i2p::tunnel::eTunnelStateExpiring) + s << " " << "Exp"; s << " " << (int)it.second->GetNumReceivedBytes () << "
"; }