diff --git a/src/powerkit_cpu.cpp b/src/powerkit_cpu.cpp index f392e42..a2a604c 100644 --- a/src/powerkit_cpu.cpp +++ b/src/powerkit_cpu.cpp @@ -427,7 +427,12 @@ const QPair Cpu::getCpuFreqLabel() int freqMin = Cpu::getMinFrequency(); int freqMax = Cpu::getMaxFrequency(); - int progress = ((currentCpuFreq - freqMin) * 100) / (freqMax - freqMin); + int progress; + if (freqMax == freqMin) { + progress = 100; + } else { + progress = ((currentCpuFreq - freqMin) * 100) / (freqMax - freqMin); + } result.first = progress; result.second = QString("%1\nGhz").arg(QString::number(currentFancyFreq / 1000000, 'f', 2));