[Kde-pim] nepomukqueryservice crash
David Faure
faure at kde.org
Sun Jul 8 10:09:31 BST 2012
On Friday 06 July 2012 14:44:30 David Faure wrote:
> Obviously the "delete localSocketModel" in nepomukmainmodel.cpp:82 is the
> problem, I assume because it's used in another thread at the same time.
OK after another look at the code, it's clearly because
nepomukmainmodel.cpp:82 can delete the model that is currently in use by other
threads.
I haven't found how to reliably trigger it though (the code says it should
happen when the local socket gets disconnected, but killing either virtuoso or
nepomukserver doesn't trigger it -- maybe due to my earlier fix in soprano...)
> The -1 file descriptor is weird too, does anyone know the reason for that?
This is the same issue, actually. Closing the connection sets the fd to -1
which makes other threads attempt to read from fd -1. Majorly thread unsafe...
I can't come up with a better solution with the one in the attached patch.
Please comment (and CC me), I'll wait for a +2 before committing.
--
David Faure, faure at kde.org, http://www.davidfaure.fr
Sponsored by Nokia to work on KDE, incl. KDE Frameworks 5
-------------- next part --------------
A non-text attachment was scrubbed...
Name: nepomukmainmodel.cpp.diff
Type: text/x-patch
Size: 1060 bytes
Desc: not available
URL: <http://mail.kde.org/pipermail/kde-pim/attachments/20120708/24d9e05d/attachment.bin>
-------------- next part --------------
_______________________________________________
KDE PIM mailing list kde-pim at kde.org
https://mail.kde.org/mailman/listinfo/kde-pim
KDE PIM home page at http://pim.kde.org/
More information about the kde-pim
mailing list