From c406177d43fbbd5ffcd9a2c51c21971326be31a9 Mon Sep 17 00:00:00 2001 From: bi4k8 Date: Tue, 9 May 2023 14:14:38 +0000 Subject: [PATCH] core: reset selected_font when clearing fonts --- src/conky.cc | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) diff --git a/src/conky.cc b/src/conky.cc index 9968d8c4..b316b18f 100644 --- a/src/conky.cc +++ b/src/conky.cc @@ -1874,10 +1874,12 @@ void clean_up(void) { for (auto output : display_outputs()) output->cleanup(); conky::shutdown_display_outputs(); #ifdef BUILD_GUI - if (!display_output() || !display_output()->graphical()) + if (!display_output() || !display_output()->graphical()) { fonts.clear(); // in set_default_configurations a font is set but not // loaded -#endif /* BUILD_GUI */ + selected_font = 0; + } +#endif /* BUILD_GUI */ if (info.first_process != nullptr) { free_all_processes();