Bug 481702

Summary: Slow and high CPU when folder contain big ".desktop" file(s)
Product: [Applications] dolphin Reporter: RenĂ© Paw Christensen <rpc>
Component: view-engine: generalAssignee: Dolphin Bug Assignee <dolphin-bugs-null>
Status: REPORTED ---    
Severity: normal CC: kfm-devel, rpc
Priority: NOR Keywords: qt6
Version: unspecified   
Target Milestone: ---   
Platform: Neon   
OS: Linux   
Latest Commit: Version Fixed In:
Sentry Crash Report:

Description René Paw Christensen 2024-02-22 22:52:56 UTC
SUMMARY
Dolphin tries to process ".desktop" file, even when it is not a text file, and when it is big.
This results in a unresponsive window.
The solution is to set a size limit, on how big ".desktop" files Dolphin should process.

STEPS TO REPRODUCE
1. Create a folder and copy a big file to it (150 MB)
2. Rename the file to ".desktop" or ".Desktop" extension
3. Browse the folder in Dolphin

OBSERVED RESULT
The window does not respond, the CPU goes high.
I expect that Dolphin tries to process the big file, because it thinks it is a text ".desktop" file.

EXPECTED RESULT
Dolphin ignorees (do not process) big ".desktop" files, perhaps > 1 MB.

SOFTWARE/OS VERSIONS
Dolphin: 24.02.0
Linux/KDE Plasma: 6.0.0
(available in About System)
KDE Plasma Version: 6.0.0
KDE Frameworks Version: 6.0.0
Qt Version: 6.6.2

ADDITIONAL INFORMATION
Nothing.