From e8ea00896d25cc5cd2e9d993050cae1379101436 Mon Sep 17 00:00:00 2001 From: ejurgensen Date: Wed, 16 Dec 2015 23:16:58 +0100 Subject: [PATCH] [listener] Fix #205 where listener_remove could break the linked list and orphan some cb's --- src/listener.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/listener.c b/src/listener.c index 92b575ba..39a35a1e 100644 --- a/src/listener.c +++ b/src/listener.c @@ -73,7 +73,7 @@ listener_remove(notify notify_cb) if (prev) prev->next = listener->next; else - listener_list = NULL; + listener_list = listener->next; free(listener); return 0;