From a58988ea9dd71eae6ae1b80933e376a9f41fa545 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Lo=C3=AFc=20Bartoletti?= Date: Tue, 4 Oct 2022 07:39:35 +0200 Subject: [PATCH] Battery: replace #else by #elif defined(__linux__) Cannot use #else here when inotify_init1() is hidden behind #if defined(__Linux__). Co-authored-by: Jan Beich --- src/modules/battery.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/modules/battery.cpp b/src/modules/battery.cpp index 143cc1b..ecf9891 100644 --- a/src/modules/battery.cpp +++ b/src/modules/battery.cpp @@ -226,7 +226,7 @@ const std::tuple waybar::modules::Battery::g //spdlog::info("{} {} {} {}", capacity,time,status,rate); return {capacity, time, status, rate}; -#else +#elif defined(__linux__) uint32_t total_power = 0; // μW >>>>>>> 246e377 (FreeBSD: Add support to battery) uint32_t total_energy = 0; // μWh