[okular] [Bug 395765] Crash when closing okular
Tobias Deiminger
bugzilla_noreply at kde.org
Mon Oct 29 20:45:10 GMT 2018
https://bugs.kde.org/show_bug.cgi?id=395765
Tobias Deiminger <haxtibal at posteo.de> changed:
What |Removed |Added
----------------------------------------------------------------------------
Resolution|--- |FIXED
Latest Commit| |https://commits.kde.org/oku
| |lar/d1ea28fc7338c24910faff7
| |7c6308a3e4f32369a
Status|CONFIRMED |RESOLVED
--- Comment #9 from Tobias Deiminger <haxtibal at posteo.de> ---
Git commit d1ea28fc7338c24910faff77c6308a3e4f32369a by Tobias Deiminger.
Committed on 29/10/2018 at 20:44.
Pushed by tobiasdeiminger into branch 'master'.
Avoid crash during session restore
Summary:
Do all access to the passed KConfigGroup really synchronous to
KMainWindow::readProperties, then we're safe.
Currently kxmlgui can't guarantee that the passed KConfigGroup is still valid
after our call to Shell::openUrl(). This is because inside Shell::openUrl,
QDialog::exec may get called. The stacked event loop processes all kinds of
asynchronous events, and litterally *anything* can happen. E.g. incoming ICE
and DBus messages may be processed. In bug 395765 it happened that XSMP
SafeYourself was processed, which calls KConfigGui::setSessionConfig, which
leaves the KConfig pointer inside KConfigGroup dangling.
Test Plan:
- get recent Qt5 and KF5
- manually save desktop session while a document is open in okular
- modify ~/.config/session/okular_<sessionid> so that Urls points to non
existing file
- manually restore session with okular -session <session_id>, dialog will open
and warn about non existent file
- okular shall not crash after closing that dialog
Reviewers: aacid
Reviewed By: aacid
Subscribers: aacid, okular-devel
Tags: #okular
Differential Revision: https://phabricator.kde.org/D16457
M +1 -1 shell/shell.cpp
https://commits.kde.org/okular/d1ea28fc7338c24910faff77c6308a3e4f32369a
--
You are receiving this mail because:
You are the assignee for the bug.
More information about the Okular-devel
mailing list