From b9b224fdc3e38080227533798ee3c4e803d2d067 Mon Sep 17 00:00:00 2001 From: orignal Date: Mon, 8 Dec 2014 21:28:11 -0500 Subject: [PATCH] fixed crash --- Garlic.cpp | 2 +- TunnelPool.cpp | 8 +------- 2 files changed, 2 insertions(+), 8 deletions(-) diff --git a/Garlic.cpp b/Garlic.cpp index 89b6fbda..42da0c08 100644 --- a/Garlic.cpp +++ b/Garlic.cpp @@ -279,7 +279,7 @@ namespace garlic uint8_t key[32], tag[32]; m_Rnd.GenerateBlock (key, 32); // random session key m_Rnd.GenerateBlock (tag, 32); // random session tag - m_Owner->AddSessionKey (key, tag); + m_Owner->SubmitSessionKey (key, tag); GarlicRoutingSession garlic (key, tag); msg = garlic.WrapSingleMessage (msg); } diff --git a/TunnelPool.cpp b/TunnelPool.cpp index c4938e8e..0adfad09 100644 --- a/TunnelPool.cpp +++ b/TunnelPool.cpp @@ -208,16 +208,10 @@ namespace tunnel } if (!failed) { - uint8_t key[32], tag[32]; - rnd.GenerateBlock (key, 32); // random session key - rnd.GenerateBlock (tag, 32); // random session tag - m_LocalDestination.SubmitSessionKey (key, tag); - i2p::garlic::GarlicRoutingSession garlic (key, tag); - uint32_t msgID = rnd.GenerateWord32 (); m_Tests[msgID] = std::make_pair (*it1, *it2); (*it1)->SendTunnelDataMsg ((*it2)->GetNextIdentHash (), (*it2)->GetNextTunnelID (), - garlic.WrapSingleMessage (CreateDeliveryStatusMsg (msgID))); + CreateDeliveryStatusMsg (msgID)); it1++; it2++; } }