Review Request: Make Sonnet::Speller::setLanguage threadsafe, fixing segfaults in krunner

Simeon Bird bladud at
Sun Sep 9 23:06:21 BST 2012

This is an automatically generated e-mail. To reply, visit:

(Updated Sept. 9, 2012, 10:06 p.m.)

Review request for kdelibs and Plasma.


v2: fix comments in review, and protect all variables, not just dict, so the whole spellchecker is thread-safe. 


Krunner's spellcheck plugin has been pretty broken since bd291d21f096a714a171e7af3a534ba345ca5659 (about two years ago) because it called Sonnet::Speller::setLanguage every time the spellchecker was invoked, which was (very much) not thread-safe.

This patch makes Sonnet::Speller::setLanguage threadsafe by protecting all access to the internal dict pointer using QReadWriteLock. 

A related review request is 106244, which adds more fixes to the spellcheck feature.

This addresses bugs 264779 and 303831.

Diffs (updated)

  kdecore/sonnet/speller.cpp b19e74d 



Compiled, installed, used for a week or so, spellchecked a bunch of things.


Simeon Bird

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <>
-------------- next part --------------
Plasma-devel mailing list
Plasma-devel at

More information about the kde-core-devel mailing list