From: Marco Bettini Date: Mon, 27 Mar 2023 08:19:38 +0000 (+0000) Subject: lib-master: stats_event_callback() - Skip if conn.output is already closed X-Git-Tag: 2.4.0~2819 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=dae0d54cfda6fa22e1a742f2c905b4425451f816;p=thirdparty%2Fdovecot%2Fcore.git lib-master: stats_event_callback() - Skip if conn.output is already closed This also prevents further errors from happening on the closed stream. --- diff --git a/src/lib-master/stats-client.c b/src/lib-master/stats-client.c index 6bff475365..3499069e1d 100644 --- a/src/lib-master/stats-client.c +++ b/src/lib-master/stats-client.c @@ -239,7 +239,7 @@ stats_event_callback(struct event *event, enum event_callback_type type, return TRUE; struct stats_client *client = (struct stats_client *)stats_clients->connections; - if (client->conn.output == NULL) + if (client->conn.output == NULL || client->conn.output->closed) return TRUE; switch (type) {