From e86a46ee4a5562f89b68a92091a26be303a4edf9 Mon Sep 17 00:00:00 2001 From: Philipp Schafft Date: Wed, 30 Sep 2020 17:28:22 +0000 Subject: [PATCH] Update: Improved statistic update logic a bit --- src/source.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/source.c b/src/source.c index b4c31b3e..9ac90234 100644 --- a/src/source.c +++ b/src/source.c @@ -423,8 +423,8 @@ void source_move_clients(source_t *source, source_t *dest) ICECAST_LOG_INFO("passing %lu listeners to \"%s\"", count, dest->mount); - source->listeners = 0; - stats_event(source->mount, "listeners", "0"); + source->listeners -= count; + stats_event_sub(source->mount, "listeners", count); } while (0); avl_tree_unlock(source->pending_tree);