mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-02-08 22:13:48 +01:00
use tunnel endpoint memroy pool to split to tunnel messages at gateway
This commit is contained in:
parent
cdc8e463b7
commit
f1990bc2ab
1 changed files with 2 additions and 3 deletions
|
@ -1,5 +1,5 @@
|
||||||
/*
|
/*
|
||||||
* Copyright (c) 2013-2020, The PurpleI2P Project
|
* Copyright (c) 2013-2021, The PurpleI2P Project
|
||||||
*
|
*
|
||||||
* This file is part of Purple i2pd project and licensed under BSD3
|
* This file is part of Purple i2pd project and licensed under BSD3
|
||||||
*
|
*
|
||||||
|
@ -158,8 +158,7 @@ namespace tunnel
|
||||||
void TunnelGatewayBuffer::CreateCurrentTunnelDataMessage ()
|
void TunnelGatewayBuffer::CreateCurrentTunnelDataMessage ()
|
||||||
{
|
{
|
||||||
m_CurrentTunnelDataMsg = nullptr;
|
m_CurrentTunnelDataMsg = nullptr;
|
||||||
m_CurrentTunnelDataMsg = NewI2NPShortMessage ();
|
m_CurrentTunnelDataMsg = NewI2NPTunnelMessage (true); // tunnel endpoint is at least of two tunnel messages size
|
||||||
m_CurrentTunnelDataMsg->Align (12);
|
|
||||||
// we reserve space for padding
|
// we reserve space for padding
|
||||||
m_CurrentTunnelDataMsg->offset += TUNNEL_DATA_MSG_SIZE + I2NP_HEADER_SIZE;
|
m_CurrentTunnelDataMsg->offset += TUNNEL_DATA_MSG_SIZE + I2NP_HEADER_SIZE;
|
||||||
m_CurrentTunnelDataMsg->len = m_CurrentTunnelDataMsg->offset;
|
m_CurrentTunnelDataMsg->len = m_CurrentTunnelDataMsg->offset;
|
||||||
|
|
Loading…
Add table
Reference in a new issue