mirror of https://github.com/xzeldon/htop.git
parent
df41979afc
commit
af84d3dfa9
|
@ -1235,7 +1235,7 @@ static inline double LinuxProcessList_scanCPUFrequency(LinuxProcessList* this) {
|
|||
(sscanf(buffer, "cpu MHz : %lf", &frequency) == 1) ||
|
||||
(sscanf(buffer, "cpu MHz: %lf", &frequency) == 1)
|
||||
) {
|
||||
if (cpuid < 0) {
|
||||
if (cpuid < 0 || cpuid > (cpus - 1)) {
|
||||
CRT_fatalError(PROCCPUINFOFILE " is malformed: cpu MHz line without corresponding processor line");
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in New Issue