sw/source/uibase/dbui/dbmgr.cxx |    4 +++-
 1 file changed, 3 insertions(+), 1 deletion(-)

New commits:
commit 33e5950bd1549c0b2e45c00e209daa20910096bf
Author:     Caolán McNamara <caolan.mcnam...@collabora.com>
AuthorDate: Mon Aug 11 08:35:56 2025 +0100
Commit:     Xisco Fauli <xiscofa...@libreoffice.org>
CommitDate: Tue Aug 12 11:35:08 2025 +0200

    cid#1659737 Dereference after null check
    
    Change-Id: I2a3da97e7a9bceedb3b9940d5625010ab215fdaf
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/189334
    Tested-by: Jenkins
    Reviewed-by: Caolán McNamara <caolan.mcnam...@collabora.com>
    (cherry picked from commit 1313be884c4ded639a5f53694c82a1cf2e77fe70)
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/189403
    Reviewed-by: Xisco Fauli <xiscofa...@libreoffice.org>

diff --git a/sw/source/uibase/dbui/dbmgr.cxx b/sw/source/uibase/dbui/dbmgr.cxx
index 12915e58f976..4590c401f156 100644
--- a/sw/source/uibase/dbui/dbmgr.cxx
+++ b/sw/source/uibase/dbui/dbmgr.cxx
@@ -1334,7 +1334,9 @@ bool SwDBManager::MergeMailFiles(SwWrtShell* pSourceShell,
                     sPrefix = aEntry.GetMainURL( 
INetURLObject::DecodeMechanism::NONE );
                 }
 
-                OUString 
sExt(comphelper::string::stripStart(pStoreToFilter->GetDefaultExtension(), 
'*'));
+                OUString sExt;
+                if (pStoreToFilter)
+                    sExt = 
comphelper::string::stripStart(pStoreToFilter->GetDefaultExtension(), '*');
                 aTempFile.reset( new utl::TempFileNamed(sLeading, 
sColumnData.isEmpty(), sExt, &sPrefix, true) );
                 if( !aTempFile->IsValid() )
                 {

Reply via email to