https://bugs.kde.org/show_bug.cgi?id=412585

            Bug ID: 412585
           Summary: po_thumbnailer crash when the po files contains no
                    string
           Product: kio-extras
           Version: 19.08.1
          Platform: Archlinux Packages
                OS: Linux
            Status: REPORTED
          Severity: crash
          Priority: NOR
         Component: Thumbnails and previews
          Assignee: plasma-b...@kde.org
          Reporter: liush...@aosc.io
  Target Milestone: ---

po_thumbnailer will crash when a PO file does not contain any translatable
string


STEPS TO REPRODUCE
1. touch empty.po
2. refresh the folder
3. crash

OBSERVED RESULT
Dr. Konqi reported a crash in kdeinit5.

EXPECTED RESULT
At least no crash

SOFTWARE/OS VERSIONS
Operating System: Arch Linux 
KDE Plasma Version: 5.16.5
KDE Frameworks Version: 5.62.0
Qt Version: 5.13.1
Kernel Version: 5.3.1-zen1-1-zen
OS Type: 64-bit
Processors: 8 × Intel® Core™ i7-6700HQ CPU @ 2.60GHz
Memory: 31.3 GiB

ADDITIONAL INFORMATION
The backtrace shows the problem is at `po_thumbnailer/pocreator.cpp:128` where
`total = 0` (division by zero).
Recommendation: add `total = total > 0 ? total : 1;` or just return with
nothing.

-- 
You are receiving this mail because:
You are watching all bug changes.

Reply via email to