sc/source/ui/condformat/condformatmgr.cxx  |    2 +-
 sw/source/ui/fldui/DateFormFieldDialog.cxx |    4 +++-
 2 files changed, 4 insertions(+), 2 deletions(-)

New commits:
commit b525c5498ef48ab72fee4874f618de5affca3fab
Author:     Caolán McNamara <[email protected]>
AuthorDate: Sun Aug 3 21:33:53 2025 +0100
Commit:     Christian Lohmaier <[email protected]>
CommitDate: Fri Aug 8 11:53:03 2025 +0200

    cid#1660815 Dereference null return value
    
    Change-Id: I47c9e02859f69df1f1849113fcb52a217eb26193
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/188888
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <[email protected]>
    (cherry picked from commit f1d7cedf2cd656bb19c68d0797b536c56f0e2683)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/189047
    Reviewed-by: Xisco Fauli <[email protected]>
    (cherry picked from commit 62df8eaee0d94dd347a10203499b714e6e1c658a)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/189062
    Reviewed-by: Christian Lohmaier <[email protected]>
    Tested-by: Christian Lohmaier <[email protected]>

diff --git a/sw/source/ui/fldui/DateFormFieldDialog.cxx 
b/sw/source/ui/fldui/DateFormFieldDialog.cxx
index d7d3fd9ea7c9..f3516e8c7306 100644
--- a/sw/source/ui/fldui/DateFormFieldDialog.cxx
+++ b/sw/source/ui/fldui/DateFormFieldDialog.cxx
@@ -42,13 +42,15 @@ DateFormFieldDialog::~DateFormFieldDialog() {}
 
 void DateFormFieldDialog::Apply()
 {
-    if (m_pDateField == nullptr)
+    if (!m_pDateField)
         return;
 
     // Try to find out the current date value and replace the content
     // with the right formatted date string
     sw::mark::Fieldmark::parameter_map_t* pParameters = 
m_pDateField->GetParameters();
     const SvNumberformat* pFormat = 
m_pNumberFormatter->GetEntry(m_xFormatLB->GetFormat());
+    if (!pFormat)
+        return;
 
     // Get date value first
     std::pair<bool, double> aResult = m_pDateField->GetCurrentDate();
commit 3f2f0deec0e431dc20861d298ce1eafac44d4607
Author:     Caolán McNamara <[email protected]>
AuthorDate: Sun Aug 3 21:48:04 2025 +0100
Commit:     Christian Lohmaier <[email protected]>
CommitDate: Fri Aug 8 11:52:50 2025 +0200

    cid#1660263 Explicit null dereferenced
    
    Change-Id: Id6d36908f93783b8b742e59861452cef00a43dca
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/188895
    Reviewed-by: Caolán McNamara <[email protected]>
    Tested-by: Jenkins
    (cherry picked from commit 916d3500d1e7cc1ee62da902552ee747493b0abd)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/189048
    Reviewed-by: Xisco Fauli <[email protected]>
    (cherry picked from commit a51a775ea87010286e6624b06e9805bcca2bb95f)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/189060
    Tested-by: Christian Lohmaier <[email protected]>
    Reviewed-by: Christian Lohmaier <[email protected]>

diff --git a/sc/source/ui/condformat/condformatmgr.cxx 
b/sc/source/ui/condformat/condformatmgr.cxx
index 2e5cef3a01a0..5e60a2a2a70d 100644
--- a/sc/source/ui/condformat/condformatmgr.cxx
+++ b/sc/source/ui/condformat/condformatmgr.cxx
@@ -124,7 +124,7 @@ std::unique_ptr<ScConditionalFormatList> 
ScCondFormatManagerDlg::GetConditionalF
 
 void ScCondFormatManagerDlg::UpdateButtonSensitivity()
 {
-    bool bNewSensitivity = !m_xFormatList->empty();
+    bool bNewSensitivity = m_xFormatList && !m_xFormatList->empty();
     m_xBtnRemove->set_sensitive(bNewSensitivity);
     m_xBtnEdit->set_sensitive(bNewSensitivity);
 }

Reply via email to