\r\n
\r\n
\r\n";
+ s << "
\r\n
\r\n
\r\n";
for(auto& it: dest->GetLeaseSets ())
s << it.second->GetIdentHash ().ToBase32 () << "
\r\n";
s << "
\r\n
\r\n";
@@ -356,13 +355,15 @@ namespace http {
}
}
s << "
\r\n";
- s << "
TagsIncoming: " << dest->GetNumIncomingTags () << "
Outgoing:
" << std::endl;
- for (const auto& it: dest->GetSessions ())
- {
- s << i2p::client::context.GetAddressBook ().ToAddress(it.first) << " ";
- s << it.second->GetNumOutgoingTags () << "
" << std::endl;
- }
- s << "
" << std::endl;
+ s << "
TagsIncoming:
" << dest->GetNumIncomingTags () << "";
+ if (!dest->GetSessions ().empty ()) {
+ s << "
\r\n
\r\n
\r\n";
+ for (const auto& it: dest->GetSessions ())
+ s << i2p::client::context.GetAddressBook ().ToAddress(it.first) << " " << it.second->GetNumOutgoingTags () << "
\r\n";
+ s << "
\r\n
\r\n";
+ } else
+ s << "Outgoing:
0\r\n";
+ s << "
\r\n";
}
void ShowLocalDestination (std::stringstream& s, const std::string& b32)
@@ -375,7 +376,7 @@ namespace http {
{
ShowLeaseSetDestination (s, dest);
// show streams
- s << "
\r\n
Streams";
+ s << "Streams\r\n";
s << "StreamID | ";
s << "Destination | ";
s << "Sent | ";
@@ -386,7 +387,7 @@ namespace http {
s << "RTT | ";
s << "Window | ";
s << "Status | ";
- s << "
";
+ s << "\r\n";
for (const auto& it: dest->GetAllStreams ())
{
@@ -401,8 +402,8 @@ namespace http {
s << "" << it->GetRTT () << " | ";
s << "" << it->GetWindowSize () << " | ";
s << "" << (int)it->GetStatus () << " | ";
- s << "
\r\n" << std::endl;
- }
+ s << "\r\n";
+ }
s << "
";
}
}
@@ -563,12 +564,12 @@ namespace http {
}
if (!tmp_s.str ().empty ())
{
- s << "\r\n
\r\n
";
+ s << "
\r\n
\r\n
";
s << tmp_s.str () << "
\r\n
\r\n";
}
if (!tmp_s6.str ().empty ())
{
- s << "
\r\n
\r\n
";
+ s << "
\r\n
\r\n
";
s << tmp_s6.str () << "
\r\n
\r\n";
}
}
@@ -579,7 +580,7 @@ namespace http {
auto sessions = ssuServer->GetSessions ();
if (!sessions.empty ())
{
- s << "
\r\n
\r\n
";
+ s << "
\r\n
\r\n
";
for (const auto& it: sessions)
{
auto endpoint = it.second->GetRemoteEndpoint ();
@@ -596,7 +597,7 @@ namespace http {
auto sessions6 = ssuServer->GetSessionsV6 ();
if (!sessions6.empty ())
{
- s << "
\r\n
\r\n
";
+ s << "
\r\n
\r\n
";
for (const auto& it: sessions6)
{
auto endpoint = it.second->GetRemoteEndpoint ();
@@ -948,7 +949,6 @@ namespace http {
i2p::win32::StopWin32App ();
#endif
} else if (cmd == HTTP_COMMAND_LOGLEVEL){
- LogPrint(eLogWarning, "HTTPServer: SetLogLevel ping 1!");
std::string level = params["level"];
SetLogLevel (level);
} else {