From 731f3b41db96b700b0ec8602ebcfbf2815f79307 Mon Sep 17 00:00:00 2001 From: brightkill Date: Sat, 8 Oct 2022 21:10:30 +0300 Subject: [PATCH] fix bug when conky displays zero values after time --- src/linux.cc | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/linux.cc b/src/linux.cc index 564a7a37..6f0be1ea 100644 --- a/src/linux.cc +++ b/src/linux.cc @@ -2375,6 +2375,8 @@ void get_battery_power_draw(char *buffer, unsigned int n, const char *bat) { result = (double)(current_now*voltage_now)/(double)1000000000000; snprintf(buffer, n, "%.1f", result); + fclose(current_now_file); + fclose(voltage_now_file); } }