mirror of
https://github.com/PurpleI2P/i2pd.git
synced 2025-01-22 13:27:17 +01:00
fixed imccorect termination
This commit is contained in:
parent
a818b0ba02
commit
18cb3912e5
|
@ -52,7 +52,6 @@ namespace transport
|
||||||
|
|
||||||
SSU2Session::~SSU2Session ()
|
SSU2Session::~SSU2Session ()
|
||||||
{
|
{
|
||||||
Terminate ();
|
|
||||||
}
|
}
|
||||||
|
|
||||||
void SSU2Session::Connect ()
|
void SSU2Session::Connect ()
|
||||||
|
@ -260,7 +259,7 @@ namespace transport
|
||||||
SendQueue ();
|
SendQueue ();
|
||||||
}
|
}
|
||||||
|
|
||||||
void SSU2Session::ProcessFirstIncomingMessage (uint64_t connID, uint8_t * buf, size_t len)
|
bool SSU2Session::ProcessFirstIncomingMessage (uint64_t connID, uint8_t * buf, size_t len)
|
||||||
{
|
{
|
||||||
// we are Bob
|
// we are Bob
|
||||||
m_SourceConnID = connID;
|
m_SourceConnID = connID;
|
||||||
|
@ -277,8 +276,12 @@ namespace transport
|
||||||
ProcessTokenRequest (header, buf, len);
|
ProcessTokenRequest (header, buf, len);
|
||||||
break;
|
break;
|
||||||
default:
|
default:
|
||||||
|
{
|
||||||
LogPrint (eLogWarning, "SSU2: Unexpected message type ", (int)header.h.type);
|
LogPrint (eLogWarning, "SSU2: Unexpected message type ", (int)header.h.type);
|
||||||
}
|
return false;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
return true;
|
||||||
}
|
}
|
||||||
|
|
||||||
void SSU2Session::SendSessionRequest (uint64_t token)
|
void SSU2Session::SendSessionRequest (uint64_t token)
|
||||||
|
|
|
@ -158,7 +158,7 @@ namespace transport
|
||||||
SSU2SessionState GetState () const { return m_State; };
|
SSU2SessionState GetState () const { return m_State; };
|
||||||
void SetState (SSU2SessionState state) { m_State = state; };
|
void SetState (SSU2SessionState state) { m_State = state; };
|
||||||
|
|
||||||
void ProcessFirstIncomingMessage (uint64_t connID, uint8_t * buf, size_t len);
|
bool ProcessFirstIncomingMessage (uint64_t connID, uint8_t * buf, size_t len);
|
||||||
bool ProcessSessionCreated (uint8_t * buf, size_t len);
|
bool ProcessSessionCreated (uint8_t * buf, size_t len);
|
||||||
bool ProcessSessionConfirmed (uint8_t * buf, size_t len);
|
bool ProcessSessionConfirmed (uint8_t * buf, size_t len);
|
||||||
bool ProcessRetry (uint8_t * buf, size_t len);
|
bool ProcessRetry (uint8_t * buf, size_t len);
|
||||||
|
|
Loading…
Reference in a new issue