--------------Boundary-00=_RWRDTSDVJ71O4RIGUJV2 Content-Type: text/plain; charset="us-ascii" Content-Transfer-Encoding: 8bit Hi, The line m_buffer.pop_front(); in "case SpellingDone" causes KoSpell::check2() to crash when m_buffer.isEmpty(). This can be triggered by pressing Shift+Enter in KWord. This has been the case for quite some time now. The attached patch appears to fix the problem. But is it correct? If so, why? Thanks, Clarence --------------Boundary-00=_RWRDTSDVJ71O4RIGUJV2 Content-Type: text/x-diff; charset="us-ascii"; name="dontcrash_linebreak.diff" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="dontcrash_linebreak.diff" Index: kospell.cc =================================================================== RCS file: /home/kde/koffice/lib/kotext/kospell.cc,v retrieving revision 1.9 diff -u -b -r1.9 kospell.cc --- kospell.cc 20 Aug 2002 09:39:39 -0000 1.9 +++ kospell.cc 8 Mar 2003 01:21:05 -0000 @@ -406,8 +407,11 @@ m_buffer << buffer; // replace '\n' with ' ' ? + // - if you want to avoid trouble later on, I would say yes. proc->fputs("^", false); - proc->fputs(buffer); + QString b = buffer; + b.replace ('\n', ' '); + proc->fputs(b); return true; } --------------Boundary-00=_RWRDTSDVJ71O4RIGUJV2-- _______________________________________________ koffice-devel mailing list koffice-devel@mail.kde.org http://mail.kde.org/mailman/listinfo/koffice-devel