Fixed a crash which could cause a double free call
This commit is contained in:
parent
05f834b47d
commit
356687b0be
@ -172,6 +172,7 @@ void WhisperHandler::handle_session_reset() {
|
|||||||
this->session_state = SessionState::Uninitialized;
|
this->session_state = SessionState::Uninitialized;
|
||||||
if(this->whisper_head_ptr) {
|
if(this->whisper_head_ptr) {
|
||||||
::free(this->whisper_head_ptr);
|
::free(this->whisper_head_ptr);
|
||||||
|
this->whisper_head_ptr = nullptr;
|
||||||
this->whisper_head_capacity = 0;
|
this->whisper_head_capacity = 0;
|
||||||
this->whisper_head_length = 0;
|
this->whisper_head_length = 0;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user