Skip to content
This repository has been archived by the owner on Jun 30, 2021. It is now read-only.

Commit

Permalink
Merge pull request #101 from tanyifeng/fix_evthr_free_leak
Browse files Browse the repository at this point in the history
fix memory leak in evthr_free when compiled with EVHTP_THR_SHARED_PIPE
  • Loading branch information
NathanFrench authored Jul 9, 2018
2 parents 8570e09 + 919e4ea commit 49260fe
Showing 1 changed file with 6 additions and 0 deletions.
6 changes: 6 additions & 0 deletions thread.c
Original file line number Diff line number Diff line change
Expand Up @@ -280,6 +280,12 @@ evthr_free(evthr_t * thread) {
event_free(thread->event);
}

#ifdef EVTHR_SHARED_PIPE
if (thread->shared_pool_ev) {
event_free(thread->shared_pool_ev);
}
#endif

if (thread->evbase) {
event_base_free(thread->evbase);
}
Expand Down

0 comments on commit 49260fe

Please sign in to comment.