cli_ure/source/climaker/climaker_app.cxx |    2 +-
 helpcompiler/source/HelpLinker.cxx       |    4 +++-
 idl/source/objects/types.cxx             |    4 ++--
 ucb/source/ucp/tdoc/tdoc_storage.cxx     |    5 +----
 4 files changed, 7 insertions(+), 8 deletions(-)

New commits:
commit ed3ce7bfeb2a22c17071fd02f61fa2c819a35c89
Author:     Caolán McNamara <[email protected]>
AuthorDate: Tue Apr 30 20:41:27 2024 +0100
Commit:     Caolán McNamara <[email protected]>
CommitDate: Wed May 1 09:17:34 2024 +0200

    WaE: C6011 Dereferencing NULL pointer warnings
    
    Change-Id: I6eb8e490e878349f2063910e0cbc901aa7a6d524
    Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166942
    Reviewed-by: Caolán McNamara <[email protected]>
    Tested-by: Jenkins

diff --git a/cli_ure/source/climaker/climaker_app.cxx 
b/cli_ure/source/climaker/climaker_app.cxx
index d551659fec4b..c389da198af5 100644
--- a/cli_ure/source/climaker/climaker_app.cxx
+++ b/cli_ure/source/climaker/climaker_app.cxx
@@ -146,7 +146,7 @@ static OptionInfo const * get_option_info(
 static bool is_option(
     OptionInfo const * option_info, sal_uInt32 * pIndex )
 {
-    OSL_ASSERT( option_info != 0 );
+    assert(option_info != 0);
     if (osl_getCommandArgCount() <= *pIndex)
         return false;
 
diff --git a/helpcompiler/source/HelpLinker.cxx 
b/helpcompiler/source/HelpLinker.cxx
index b99061d0dd7f..70b9af1fe4b4 100644
--- a/helpcompiler/source/HelpLinker.cxx
+++ b/helpcompiler/source/HelpLinker.cxx
@@ -709,7 +709,9 @@ void HelpLinker::main( std::vector<std::string> &args,
             }
         }
         else
-        { //called from extension manager
+        {
+            assert(pExtensionPath);
+            //called from extension manager
             extensionPath = *pExtensionPath;
             sourceRoot = fs::path(extensionPath);
             extensionDestination = *pDestination;
diff --git a/idl/source/objects/types.cxx b/idl/source/objects/types.cxx
index 1089e929043c..f6a77e77e07a 100644
--- a/idl/source/objects/types.cxx
+++ b/idl/source/objects/types.cxx
@@ -99,9 +99,9 @@ bool SvMetaAttribute::ReadSvIdl( SvIdlDataBase & rBase,
 size_t SvMetaAttribute::MakeSfx( OStringBuffer& rAttrArray ) const
 {
     SvMetaType * pType = GetType();
-    DBG_ASSERT( pType, "no type for attribute" );
+    assert(pType && "no type for attribute");
     SvMetaType * pBaseType = pType->GetBaseType();
-    DBG_ASSERT( pBaseType, "no base type for attribute" );
+    assert(pBaseType && "no base type for attribute");
     if( pBaseType->GetMetaTypeType() == MetaTypeType::Struct )
         return pBaseType->MakeSfx( rAttrArray );
     else
diff --git a/ucb/source/ucp/tdoc/tdoc_storage.cxx 
b/ucb/source/ucp/tdoc/tdoc_storage.cxx
index fe307a5bfa2d..858b05784dcc 100644
--- a/ucb/source/ucp/tdoc/tdoc_storage.cxx
+++ b/ucb/source/ucp/tdoc/tdoc_storage.cxx
@@ -319,19 +319,16 @@ StorageElementFactory::createStream( const OUString & 
rUri,
         new Stream( m_xContext, m_xDocsMgr, rUri, xParentStorage, xStream ) );
 }
 
-
 void StorageElementFactory::releaseElement( Storage const * pElement )
 {
-    OSL_ASSERT( pElement );
+    assert(pElement);
     osl::MutexGuard aGuard( m_aMutex );
     if ( pElement->m_aContainerIt != m_aMap.end() )
         m_aMap.erase( pElement->m_aContainerIt );
 }
 
-
 // Non-UNO interface
 
-
 uno::Reference< embed::XStorage > StorageElementFactory::queryParentStorage(
         const OUString & rUri, StorageAccessMode eMode )
 {

Reply via email to