From b1a6c5ddf7787b4275ec77730f59fa1324159d6c Mon Sep 17 00:00:00 2001 From: orignal Date: Fri, 16 Mar 2018 11:12:18 -0400 Subject: [PATCH] fixed build for gcc 4.7 --- libi2pd/NTCPSession.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/libi2pd/NTCPSession.cpp b/libi2pd/NTCPSession.cpp index e3d6c004..e0bd1135 100644 --- a/libi2pd/NTCPSession.cpp +++ b/libi2pd/NTCPSession.cpp @@ -178,7 +178,8 @@ namespace transport } // TODO: check for number of pending keys auto s = shared_from_this (); - m_Server.Work(s, [s]() -> std::function { + // TODO: we need to pass this for gcc 4.7, should be removed later on + m_Server.Work(s, [s, this]() -> std::function { if (!s->m_DHKeysPair) s->m_DHKeysPair = transports.GetNextDHKeysPair (); s->CreateAESKey (s->m_Establisher->phase1.pubKey); @@ -242,7 +243,8 @@ namespace transport else { auto s = shared_from_this (); - m_Server.Work(s, [s]() -> std::function { + // TODO: we need to pass this for gcc 4.7, should be removed later on + m_Server.Work(s, [s, this]() -> std::function { s->CreateAESKey (s->m_Establisher->phase2.pubKey); return std::bind(&NTCPSession::HandlePhase2, s); });