diff --git a/src/linux/btop_collect.cpp b/src/linux/btop_collect.cpp index 468fd6d..bf869df 100644 --- a/src/linux/btop_collect.cpp +++ b/src/linux/btop_collect.cpp @@ -333,7 +333,16 @@ namespace Cpu { } catch (...) {} - if (not got_coretemp or core_sensors.empty()) cpu_temp_only = true; + if (not got_coretemp or core_sensors.empty()) { + cpu_temp_only = true; + } + else { + rng::sort(core_sensors, rng::less{}); + rng::stable_sort(core_sensors, [](const auto& a, const auto& b){ + return a.size() < b.size(); + }); + } + if (cpu_sensor.empty() and not found_sensors.empty()) { for (const auto& [name, sensor] : found_sensors) { if (s_contains(str_to_lower(name), "cpu") or s_contains(str_to_lower(name), "k10temp")) {