Browse Source

don't wait for remote LeaseSet request complete

pull/167/head
orignal 10 years ago
parent
commit
3f4bd13091
  1. 11
      Streaming.cpp
  2. 1
      Streaming.h

11
Streaming.cpp

@ -607,19 +607,10 @@ namespace stream @@ -607,19 +607,10 @@ namespace stream
{
LogPrint (eLogInfo, "All leases are expired. Trying to request");
m_RemoteLeaseSet = nullptr;
m_LocalDestination.GetOwner ().RequestDestination (m_RemoteIdentity.GetIdentHash (),
std::bind (&Stream::HandleLeaseSetRequestComplete, shared_from_this (), std::placeholders::_1));
m_LocalDestination.GetOwner ().RequestDestination (m_RemoteIdentity.GetIdentHash ());
}
}
void Stream::HandleLeaseSetRequestComplete (bool success)
{
if (success)
{
LogPrint (eLogInfo, "New LeaseSet found");
UpdateCurrentRemoteLease ();
}
}
void Stream::ScheduleResend ()
{

1
Streaming.h

@ -147,7 +147,6 @@ namespace stream @@ -147,7 +147,6 @@ namespace stream
template<typename Buffer, typename ReceiveHandler>
void HandleReceiveTimer (const boost::system::error_code& ecode, const Buffer& buffer, ReceiveHandler handler);
void HandleLeaseSetRequestComplete (bool success);
void ScheduleResend ();
void HandleResendTimer (const boost::system::error_code& ecode);

Loading…
Cancel
Save