mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-02-02 19:24:14 +00:00
fixed crash
This commit is contained in:
parent
cb06f8e0bb
commit
b9b224fdc3
@ -279,7 +279,7 @@ namespace garlic
|
|||||||
uint8_t key[32], tag[32];
|
uint8_t key[32], tag[32];
|
||||||
m_Rnd.GenerateBlock (key, 32); // random session key
|
m_Rnd.GenerateBlock (key, 32); // random session key
|
||||||
m_Rnd.GenerateBlock (tag, 32); // random session tag
|
m_Rnd.GenerateBlock (tag, 32); // random session tag
|
||||||
m_Owner->AddSessionKey (key, tag);
|
m_Owner->SubmitSessionKey (key, tag);
|
||||||
GarlicRoutingSession garlic (key, tag);
|
GarlicRoutingSession garlic (key, tag);
|
||||||
msg = garlic.WrapSingleMessage (msg);
|
msg = garlic.WrapSingleMessage (msg);
|
||||||
}
|
}
|
||||||
|
@ -208,16 +208,10 @@ namespace tunnel
|
|||||||
}
|
}
|
||||||
if (!failed)
|
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 ();
|
uint32_t msgID = rnd.GenerateWord32 ();
|
||||||
m_Tests[msgID] = std::make_pair (*it1, *it2);
|
m_Tests[msgID] = std::make_pair (*it1, *it2);
|
||||||
(*it1)->SendTunnelDataMsg ((*it2)->GetNextIdentHash (), (*it2)->GetNextTunnelID (),
|
(*it1)->SendTunnelDataMsg ((*it2)->GetNextIdentHash (), (*it2)->GetNextTunnelID (),
|
||||||
garlic.WrapSingleMessage (CreateDeliveryStatusMsg (msgID)));
|
CreateDeliveryStatusMsg (msgID));
|
||||||
it1++; it2++;
|
it1++; it2++;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user