[Nepomuk] Review Request 108997: Fix bug 292950 by deleting QCoreApplication only after Storage->ServerCore.

Simeon Bird bladud at gmail.com
Fri Mar 8 04:55:54 UTC 2013


-----------------------------------------------------------
This is an automatically generated e-mail. To reply, visit:
http://git.reviewboard.kde.org/r/108997/
-----------------------------------------------------------

(Updated March 8, 2013, 4:55 a.m.)


Review request for Nepomuk and Vishesh Handa.


Changes
-------

New cunning plan: do not require action on the part of services other than the storage.


Description (updated)
-------

Fix bug 292950 by deleting QCoreApplication only after Storage->ServerCore.

The bug occurs because Storage->ServerCore may persist after
QCoreApplication is gone. If the socket receives a remote disconnected
message from virtuoso (which it might because this is shutdown and
virtuoso is being killed) it tries to translate it, but can't because
the translators went with QCoreApplication. Thus the crash.

This was made much less likely by Vishesh already with cea2870f04eec
but we can do better.

For most services connect QCoreApplication::quit() to the service destroyed() signal.
For the storage service, disconnect that slot from the service and reconnect it to 
ServerCore::destroyed() (so that the application is only quit after the
ServerCore destructor runs). We do this in the service dtor, which is allowed because the 
dtor runs before destroyed() is emitted (I checked this).

BUG: 292950
FIXED-IN: 4.10.1


This addresses bug 292950.
    http://bugs.kde.org/show_bug.cgi?id=292950


Diffs (updated)
-----

  services/storage/storage.cpp 16f7fd483eeb462227287c797c4619c78c23092d 
  servicestub/servicecontrol.cpp 97f96d4ed33c452fdc91ea666c91b6fbced1e461 

Diff: http://git.reviewboard.kde.org/r/108997/diff/


Testing
-------

Compiled, checked shutdown and restart


Thanks,

Simeon Bird

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.kde.org/pipermail/nepomuk/attachments/20130308/9b052215/attachment.html>


More information about the Nepomuk mailing list