Browse Source

adding files to а VS project, showed external ip on statistics page

pull/45/head
chertov 11 years ago
parent
commit
7f26296759
  1. 14
      HTTPServer.cpp
  2. 2
      Win32/i2pd.vcxproj
  3. 6
      Win32/i2pd.vcxproj.filters

14
HTTPServer.cpp

@ -118,6 +118,20 @@ namespace util @@ -118,6 +118,20 @@ namespace util
void HTTPConnection::FillContent (std::stringstream& s)
{
s << "Our external address:" << "<BR>" << "<BR>";
for (auto& address : i2p::context.GetRouterInfo().GetAddresses())
{
switch (address.transportStyle) {
case i2p::data::RouterInfo::eTransportNTCP:
s << "NTCP&nbsp;&nbsp;";
break;
case i2p::data::RouterInfo::eTransportSSU:
s << "SSU&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;";
break;
}
s << address.host.to_string() << ":" << address.port << "<BR>";
}
s << "<P>Tunnels</P>";
for (auto it: i2p::tunnel::tunnels.GetOutboundTunnels ())
{

2
Win32/i2pd.vcxproj

@ -32,6 +32,7 @@ @@ -32,6 +32,7 @@
<ClCompile Include="..\Tunnel.cpp" />
<ClCompile Include="..\TunnelEndpoint.cpp" />
<ClCompile Include="..\TunnelGateway.cpp" />
<ClCompile Include="..\UPnP.cpp" />
<ClCompile Include="..\util.cpp" />
</ItemGroup>
<ItemGroup>
@ -62,6 +63,7 @@ @@ -62,6 +63,7 @@
<ClInclude Include="..\TunnelConfig.h" />
<ClInclude Include="..\TunnelEndpoint.h" />
<ClInclude Include="..\TunnelGateway.h" />
<ClInclude Include="..\UPnP.h" />
<ClInclude Include="..\util.h" />
</ItemGroup>
<PropertyGroup Label="Globals">

6
Win32/i2pd.vcxproj.filters

@ -81,6 +81,9 @@ @@ -81,6 +81,9 @@
<ClCompile Include="..\Reseed.cpp">
<Filter>Source Files</Filter>
</ClCompile>
<ClCompile Include="..\UPnP.cpp">
<Filter>Source Files</Filter>
</ClCompile>
</ItemGroup>
<ItemGroup>
<ClInclude Include="..\Identity.h">
@ -167,5 +170,8 @@ @@ -167,5 +170,8 @@
<ClInclude Include="..\Reseed.h">
<Filter>Header Files</Filter>
</ClInclude>
<ClInclude Include="..\UPnP.h">
<Filter>Header Files</Filter>
</ClInclude>
</ItemGroup>
</Project>
Loading…
Cancel
Save