# HG changeset patch # User Timo Sirainen # Date 1317562431 -10800 # Node ID f41a3dd03be2e1e22850ed96971d1bcdbc324e24 # Parent 7f7724f28d78a24fc88d9e15ddbb59932ed1b397 ioloop: Memory leak fix on ioloop destroy. diff -r 7f7724f28d78 -r f41a3dd03be2 src/lib/ioloop.c --- a/src/lib/ioloop.c Sun Oct 02 16:32:59 2011 +0300 +++ b/src/lib/ioloop.c Sun Oct 02 16:33:51 2011 +0300 @@ -474,6 +474,9 @@ if (ioloop->handler_context != NULL) io_loop_handler_deinit(ioloop); + if (ioloop->cur_ctx != NULL) + io_loop_context_deactivate(ioloop->cur_ctx); + /* ->prev won't work unless loops are destroyed in create order */ i_assert(ioloop == current_ioloop); current_ioloop = current_ioloop->prev;