Bug 390806 - kmail sleeping after opening an attachment
Summary: kmail sleeping after opening an attachment
Status: RESOLVED FIXED
Alias: None
Product: kmail2
Classification: Applications
Component: general (show other bugs)
Version: 5.7.2
Platform: Arch Linux Linux
: NOR normal
Target Milestone: ---
Assignee: kdepim bugs
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2018-02-20 19:45 UTC by Martin Schnitkemper
Modified: 2023-03-16 10:15 UTC (History)
2 users (show)

See Also:
Latest Commit:
Version Fixed In:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Martin Schnitkemper 2018-02-20 19:45:39 UTC
After opening an attachment, kmail does not remove its process on exit. It is not possible to launch kmail again, unless I kill the previous process.  In fact, a second process is starting but kmail does not appear. 

If launching kmail on console I get these messages after opening a PDF:

| command= "okular %U" args= ("okular %U", "file:///tmp/messageviewer_attachment_JpSXKU/RE1258538069258.pdf")
| EXEC  "/usr/bin/okular /tmp/messageviewer_attachment_JpSXKU/RE1258538069258.pdf"
| EXEC done
| sleeping...

This happen with every kind of attachment.
Comment 1 Laurent Montel 2018-02-21 08:28:35 UTC
I confirm it.
it seems to be a bug in kf5 framework as we use kf5 method.
Comment 2 Jonathan Marten 2018-02-21 12:22:12 UTC
The console messages above are from kioexec, which was a fix implemented a long time ago for bug 130709.  kioexec sleeps for 180 seconds after starting the application but before removing the temporary file, so that if the application forks and the parent returns immediately the file will not be removed before the child application has the chance to open it.

If you wait for 3 minutes after opening the attachment, then you will find that kmail exits correctly.

The question, therefore, is why kmail is waiting for the opening of the attachment to finish - it should launch it in a separate background process.
Comment 3 Martin Schnitkemper 2023-03-16 10:15:40 UTC
The problem has now been fixed and no longer occurs.
[kmail2 5.22.3 (22.12.3) | KDE Plasma version: 5.27.2 | KDE Framework Version: 5.103.0 | Qt version: 5.15.8]