diff options
author | Miklos Vajna <vmiklos@collabora.com> | 2022-09-28 09:09:03 +0200 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2022-10-02 20:42:02 +0200 |
commit | 2f2f39309c33800f6b751062f26b645d4fd9b050 (patch) | |
tree | 40a40fc42b7f884b036674fbe84388496a701cab | |
parent | tdf#151148 Finding KATAKANA which has voice consonant mark wrong (diff) | |
download | core-2f2f39309c33800f6b751062f26b645d4fd9b050.tar.gz core-2f2f39309c33800f6b751062f26b645d4fd9b050.zip |
cui: fix crash in SpellDialog::SpellContinue_Impl
Crashreport signature:
Fatal signal received: SIGSEGV code: 128 for address: 0x0
program/libcuilo.so
svx::SpellDialog::GetNextSentence_Impl(std::unique_ptr<UndoChangeGroupGuard, std::default_delete<UndoChangeGroupGuard> >*, bool, bool)
include/com/sun/star/uno/Reference.hxx:114
program/libcuilo.so
svx::SpellDialog::SpellContinue_Impl(std::unique_ptr<UndoChangeGroupGuard, std::default_delete<UndoChangeGroupGuard> >*, bool, bool)
cui/source/dialogs/SpellDialog.cxx:355
program/libcuilo.so
svx::SpellDialog::ChangeHdl(weld::Button&)
include/rtl/ustring.hxx:527
program/libmergedlo.so
Control::ImplCallEventListenersAndHandler(VclEventId, std::function<void ()> const&)
include/rtl/ref.hxx:208
program/libmergedlo.so
Button::Click()
/opt/rh/devtoolset-10/root/usr/include/c++/10/bits/std_function.h:244
Change-Id: I2c7267118213ea7d915a28d77badf93f8ff75683
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140586
Tested-by: Jenkins CollaboraOffice <jenkinscollaboraoffice@gmail.com>
Reviewed-by: Miklos Vajna <vmiklos@collabora.com>
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140689
Tested-by: Jenkins
(cherry picked from commit 9be24f694d42fc9cae55ed911e0dff7f729803f1)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140611
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
(cherry picked from commit ae1f8a426338770f0dd46c72553c405158415e65)
Reviewed-on: https://gerrit.libreoffice.org/c/core/+/140761
-rw-r--r-- | cui/source/dialogs/SpellDialog.cxx | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/cui/source/dialogs/SpellDialog.cxx b/cui/source/dialogs/SpellDialog.cxx index 329b20d54e29..9f110c6a5aa1 100644 --- a/cui/source/dialogs/SpellDialog.cxx +++ b/cui/source/dialogs/SpellDialog.cxx @@ -351,6 +351,11 @@ void SpellDialog::SpellContinue_Impl(std::unique_ptr<UndoChangeGroupGuard>* pGua //then GetNextSentence() has to be called followed again by MarkNextError() //MarkNextError is not initially called if the UndoEdit mode is active bool bNextSentence = false; + if (!m_xSentenceED) + { + return; + } + if(!((!m_xSentenceED->IsUndoEditMode() && m_xSentenceED->MarkNextError( bIgnoreCurrentError, xSpell )) || ( bNextSentence = GetNextSentence_Impl(pGuard, bUseSavedSentence, m_xSentenceED->IsUndoEditMode()) && m_xSentenceED->MarkNextError( false, xSpell )))) return; |