From d089d2691a24a1d9bdbb02e350405843c808d2bc Mon Sep 17 00:00:00 2001 From: Ruben Kerkhof Date: Sat, 25 Jul 2015 12:32:06 +0200 Subject: [PATCH] Fix a memory leak on shutdown --- src/plugin.c | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) diff --git a/src/plugin.c b/src/plugin.c index 5d31e46f..97352c47 100644 --- a/src/plugin.c +++ b/src/plugin.c @@ -181,13 +181,13 @@ static void destroy_read_heap (void) /* {{{ */ while (42) { - callback_func_t *cf; + read_func_t *rf; - cf = c_heap_get_root (read_heap); - if (cf == NULL) + rf = c_heap_get_root (read_heap); + if (rf == NULL) break; - - destroy_callback (cf); + sfree (rf->rf_name); + destroy_callback ((callback_func_t *) rf); } c_heap_destroy (read_heap); -- 2.11.0