[prev in list] [next in list] [prev in thread] [next in thread] 

List:       kde-panel-devel
Subject:    Review Request: Make Sonnet::Speller::setLanguage threadsafe, fixing segfaults in krunner
From:       "Simeon Bird" <bladud () gmail ! com>
Date:       2012-08-27 21:33:38
Message-ID: 20120827213338.8444.46256 () vidsolbach ! de
[Download RAW message or body]

[Attachment #2 (multipart/alternative)]


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

Review request for kdelibs and Plasma.


Description
-------

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.
    http://bugs.kde.org/show_bug.cgi?id=264779
    http://bugs.kde.org/show_bug.cgi?id=303831


Diffs
-----

  kdecore/sonnet/speller.cpp b19e74d 

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


Testing
-------

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


Thanks,

Simeon Bird


[Attachment #5 (text/html)]

<html>
 <body>
  <div style="font-family: Verdana, Arial, Helvetica, Sans-Serif;">
   <table bgcolor="#f9f3c9" width="100%" cellpadding="8" style="border: 1px #c9c399 \
solid;">  <tr>
     <td>
      This is an automatically generated e-mail. To reply, visit:
      <a href="http://git.reviewboard.kde.org/r/106242/">http://git.reviewboard.kde.org/r/106242/</a>
  </td>
    </tr>
   </table>
   <br />


<table bgcolor="#fefadf" width="100%" cellspacing="0" cellpadding="8" \
style="background-image: \
url('http://git.reviewboard.kde.org/media/rb/images/review_request_box_top_bg.png'); \
background-position: left top; background-repeat: repeat-x; border: 1px black \
solid;">  <tr>
  <td>

<div>Review request for kdelibs and Plasma.</div>
<div>By Simeon Bird.</div>







<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Description </h1>
 <table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" \
style="border: 1px solid #b8b5a0">  <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">Krunner&#39;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.</pre>  </td>
 </tr>
</table>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Testing </h1>
<table width="100%" bgcolor="#ffffff" cellspacing="0" cellpadding="10" style="border: \
1px solid #b8b5a0">  <tr>
  <td>
   <pre style="margin: 0; padding: 0; white-space: pre-wrap; white-space: \
-moz-pre-wrap; white-space: -pre-wrap; white-space: -o-pre-wrap; word-wrap: \
break-word;">Compiled, installed, used for a week or so, spellchecked a bunch of \
things.</pre>  </td>
 </tr>
</table>



<div style="margin-top: 1.5em;">
 <b style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Bugs: </b>


 <a href="http://bugs.kde.org/show_bug.cgi?id=264779">264779</a>, 

 <a href="http://bugs.kde.org/show_bug.cgi?id=303831">303831</a>


</div>


<h1 style="color: #575012; font-size: 10pt; margin-top: 1.5em;">Diffs</b> </h1>
<ul style="margin-left: 3em; padding-left: 0;">

 <li>kdecore/sonnet/speller.cpp <span style="color: grey">(b19e74d)</span></li>

</ul>

<p><a href="http://git.reviewboard.kde.org/r/106242/diff/" style="margin-left: \
3em;">View Diff</a></p>




  </td>
 </tr>
</table>




  </div>
 </body>
</html>



_______________________________________________
Plasma-devel mailing list
Plasma-devel@kde.org
https://mail.kde.org/mailman/listinfo/plasma-devel


[prev in list] [next in list] [prev in thread] [next in thread] 

Configure | About | News | Add a list | Sponsored by KoreLogic