From 7873b05c4bfa776ae90145a7689591c66b0913d6 Mon Sep 17 00:00:00 2001 From: Mattias Andrée Date: Wed, 13 Jul 2016 02:45:39 +0200 Subject: Only remove filter when a connection closes if the filter has until-death lifespan MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Signed-off-by: Mattias Andrée --- src/server.c | 1 + 1 file changed, 1 insertion(+) (limited to 'src') diff --git a/src/server.c b/src/server.c index 06d88da..4b1f939 100644 --- a/src/server.c +++ b/src/server.c @@ -301,6 +301,7 @@ static int connection_closed(int client) for (j = k = 0; j < output->table_size; j += !remove, k++) { remove = output->table_filters[j].client == client; + remove = remove && (output->table_filters[j].lifespan == LIFESPAN_UNTIL_DEATH); if (remove) { filter_destroy(output->table_filters + j); -- cgit v1.2.3-70-g09d2