From f4be5e16f282fd5a1aeb54520e2152fa292a2910 Mon Sep 17 00:00:00 2001 From: Harald Welte Date: Sun, 24 Jul 2022 13:36:46 +0200 Subject: [PATCH] bankd: Don't log an "Error" if slotmap is removed removing a slotmap and the related client disconnect are perfectly normal operation. Don't print the word Error in the log in such cases, it just confuses the user. Closes: OS#5629 Change-Id: Ie39d35fd348fdf3dd53c860dc830aac794a3ead5 --- src/bankd/bankd_main.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/src/bankd/bankd_main.c b/src/bankd/bankd_main.c index c2d6e69..b3b8dff 100644 --- a/src/bankd/bankd_main.c +++ b/src/bankd/bankd_main.c @@ -986,7 +986,10 @@ static void *worker_main(void *arg) break; } - LOGW(g_worker, "Error %d occurred: Cleaning up state\n", rc); + if (rc == -23) + LOGW(g_worker, "Client unmapped: Cleaning up state\n"); + else + LOGW(g_worker, "Error %d occurred: Cleaning up state\n", rc); /* clean-up: reset to sane state */ memset(&g_worker->card, 0, sizeof(g_worker->card));