Browse Source

don't copy temporary data structure

pull/48/head
orignal 11 years ago
parent
commit
d32f345aee
  1. 2
      TunnelGateway.cpp
  2. 2
      TunnelGateway.h

2
TunnelGateway.cpp

@ -107,7 +107,7 @@ namespace tunnel
} }
} }
std::vector<I2NPMessage *> TunnelGatewayBuffer::GetTunnelDataMsgs () const std::vector<I2NPMessage *> TunnelGatewayBuffer::GetTunnelDataMsgs ()
{ {
CompleteCurrentTunnelDataMessage (); CompleteCurrentTunnelDataMessage ();
std::vector<I2NPMessage *> ret = m_TunnelDataMsgs; // TODO: implement it better std::vector<I2NPMessage *> ret = m_TunnelDataMsgs; // TODO: implement it better

2
TunnelGateway.h

@ -16,7 +16,7 @@ namespace tunnel
TunnelGatewayBuffer (uint32_t tunnelID): m_TunnelID (tunnelID), TunnelGatewayBuffer (uint32_t tunnelID): m_TunnelID (tunnelID),
m_CurrentTunnelDataMsg (nullptr), m_RemainingSize (0) {}; m_CurrentTunnelDataMsg (nullptr), m_RemainingSize (0) {};
void PutI2NPMsg (const TunnelMessageBlock& block); void PutI2NPMsg (const TunnelMessageBlock& block);
std::vector<I2NPMessage *> GetTunnelDataMsgs (); const std::vector<I2NPMessage *> GetTunnelDataMsgs ();
private: private:

Loading…
Cancel
Save