initial outproxy support for http proxy

This commit is contained in:
Jeff Becker
2016-11-20 09:25:56 -05:00
parent 3125e05b49
commit f1370189b6
5 changed files with 185 additions and 28 deletions

View File

@@ -97,14 +97,14 @@ namespace client
while (m_IsRunning)
{
try
{
{
m_Service.run ();
}
catch (std::exception& ex)
{
LogPrint (eLogError, "Destination: runtime exception: ", ex.what ());
}
}
LogPrint (eLogError, "Destination: Runtime Exception", ex.what ());
}
}
}
bool LeaseSetDestination::Start ()
@@ -113,7 +113,7 @@ namespace client
{
m_IsRunning = true;
m_Pool->SetLocalDestination (shared_from_this ());
m_Pool->SetActive (true);
m_Pool->SetActive (true);
m_Thread = new std::thread (std::bind (&LeaseSetDestination::Run, shared_from_this ()));
m_CleanupTimer.expires_from_now (boost::posix_time::minutes (DESTINATION_CLEANUP_TIMEOUT));
@@ -137,7 +137,7 @@ namespace client
{
m_Pool->SetLocalDestination (nullptr);
i2p::tunnel::tunnels.StopTunnelPool (m_Pool);
}
}
m_Service.stop ();
if (m_Thread)
{
@@ -622,8 +622,8 @@ namespace client
if (done)
{
auto requestComplete = it->second;
m_LeaseSetRequests.erase (it);
if (requestComplete) requestComplete->Complete (nullptr);
m_LeaseSetRequests.erase (it);
}
}
}