1
0
mirror of https://github.com/PurpleI2P/i2pd.git synced 2025-01-22 12:24:19 +00:00

don't crash on os x when no lease set found for udp tunnel

This commit is contained in:
Jeff 2016-12-17 06:35:38 -05:00
parent c009e6bd04
commit ae3bb30d8a

View File

@ -293,6 +293,7 @@ namespace datagram
void DatagramSession::HandleLeaseSetUpdated(std::shared_ptr<i2p::data::LeaseSet> ls) void DatagramSession::HandleLeaseSetUpdated(std::shared_ptr<i2p::data::LeaseSet> ls)
{ {
if(!ls) return;
// only update lease set if found and newer than previous lease set // only update lease set if found and newer than previous lease set
uint64_t oldExpire = 0; uint64_t oldExpire = 0;
if(m_RemoteLeaseSet) oldExpire = m_RemoteLeaseSet->GetExpirationTime(); if(m_RemoteLeaseSet) oldExpire = m_RemoteLeaseSet->GetExpirationTime();