From 4193aa864cbf4f36d264179f9be1999ce74e77e6 Mon Sep 17 00:00:00 2001 From: Adam Dickmeiss Date: Thu, 11 Mar 2010 14:56:34 +0100 Subject: [PATCH] iochan_man_destroy destroys channels --- src/eventl.c | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/eventl.c b/src/eventl.c index 3eff731..40f7a69 100644 --- a/src/eventl.c +++ b/src/eventl.c @@ -78,8 +78,17 @@ void iochan_man_destroy(iochan_man_t *mp) { if (*mp) { + IOCHAN c; if ((*mp)->sel_thread) sel_thread_destroy((*mp)->sel_thread); + + c = (*mp)->channel_list; + while (c) + { + IOCHAN c_next = c->next; + xfree(c); + c = c_next; + } xfree(*mp); *mp = 0; } -- 1.7.10.4