[Libreoffice-commits] core.git: cui/source
Caolán McNamara (via logerrit)
logerrit at kemper.freedesktop.org
Tue Jul 23 07:32:30 UTC 2019
cui/source/tabpages/autocdlg.cxx | 12 ++++++++++--
1 file changed, 10 insertions(+), 2 deletions(-)
New commits:
commit 08c393a3d26dc336db790ad1900d598a039417b8
Author: Caolán McNamara <caolanm at redhat.com>
AuthorDate: Mon Jul 22 12:18:31 2019 +0100
Commit: Caolán McNamara <caolanm at redhat.com>
CommitDate: Tue Jul 23 09:31:34 2019 +0200
cid#1448463 Dereference null return value
Change-Id: I61285b8e34f58bbaaedb5fd67d181aee7e1e591d
Reviewed-on: https://gerrit.libreoffice.org/76135
Tested-by: Jenkins
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/cui/source/tabpages/autocdlg.cxx b/cui/source/tabpages/autocdlg.cxx
index 2ed5e4ac7c0c..3d4b86d637ba 100644
--- a/cui/source/tabpages/autocdlg.cxx
+++ b/cui/source/tabpages/autocdlg.cxx
@@ -171,9 +171,17 @@ IMPL_LINK_NOARG(OfaAutoCorrDlg, SelectLanguageHdl, weld::ComboBox&, void)
{
OString sPageId = GetCurPageId();
if (sPageId == "replace")
- static_cast<OfaAutocorrReplacePage*>(GetTabPage(sPageId))->SetLanguage(eNewLang);
+ {
+ OfaAutocorrReplacePage* pPage = static_cast<OfaAutocorrReplacePage*>(GetTabPage(sPageId));
+ assert(pPage);
+ pPage->SetLanguage(eNewLang);
+ }
else if (sPageId == "exceptions")
- static_cast<OfaAutocorrExceptPage*>(GetTabPage(sPageId))->SetLanguage(eNewLang);
+ {
+ OfaAutocorrExceptPage* pPage = static_cast<OfaAutocorrExceptPage*>(GetTabPage(sPageId));
+ assert(pPage);
+ pPage->SetLanguage(eNewLang);
+ }
}
}
More information about the Libreoffice-commits
mailing list