[Libreoffice-commits] core.git: sc/source

Caolán McNamara (via logerrit) logerrit at kemper.freedesktop.org
Tue Oct 29 08:20:08 UTC 2019


 sc/source/ui/formdlg/formula.cxx |    5 ++---
 1 file changed, 2 insertions(+), 3 deletions(-)

New commits:
commit af16372211927c3ed1b3cc760ec182c30fda491c
Author:     Caolán McNamara <caolanm at redhat.com>
AuthorDate: Mon Oct 28 19:21:44 2019 +0000
Commit:     Caolán McNamara <caolanm at redhat.com>
CommitDate: Tue Oct 29 09:18:58 2019 +0100

    cid#1453992 Dereference after null check
    
    presumably pInputHdl cannot be null
    
    Change-Id: If7fe7b43a23c5d917a18b09f46226c5b8e6009a1
    Reviewed-on: https://gerrit.libreoffice.org/81626
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/sc/source/ui/formdlg/formula.cxx b/sc/source/ui/formdlg/formula.cxx
index d71351840b85..784281c57185 100644
--- a/sc/source/ui/formdlg/formula.cxx
+++ b/sc/source/ui/formdlg/formula.cxx
@@ -96,10 +96,9 @@ ScFormulaDlg::ScFormulaDlg(SfxBindings* pB, SfxChildWindow* pCW,
 
     ScInputHandler* pInputHdl = SC_MOD()->GetInputHdl(m_pViewShell);
 
-    OSL_ENSURE( pInputHdl, "Missing input handler :-/" );
+    assert(pInputHdl && "Missing input handler :-/");
 
-    if ( pInputHdl )
-        pInputHdl->NotifyChange( nullptr );
+    pInputHdl->NotifyChange( nullptr );
 
     ScFormulaReferenceHelper::enableInput( true );
     ScFormulaReferenceHelper::EnableSpreadsheets();


More information about the Libreoffice-commits mailing list