mirror of
https://github.com/pikami/slstatus.git
synced 2024-11-30 07:15:42 +00:00
Fix a little logic error
This commit is contained in:
parent
e1e1b1d79a
commit
0f7e022381
@ -169,7 +169,7 @@ cpu_freq(void)
|
|||||||
int freq;
|
int freq;
|
||||||
|
|
||||||
return (pscanf("/sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq",
|
return (pscanf("/sys/devices/system/cpu/cpu0/cpufreq/scaling_cur_freq",
|
||||||
"%i", &freq) != 1) ?
|
"%i", &freq) == 1) ?
|
||||||
bprintf("%d", (freq + 500) / 1000) : unknown_str;
|
bprintf("%d", (freq + 500) / 1000) : unknown_str;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user