WaE: C6011 Dereferencing NULL pointer warnings
Change-Id: I6eb8e490e878349f2063910e0cbc901aa7a6d524 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/166942 Reviewed-by: Caolán McNamara <caolan.mcnamara@collabora.com> Tested-by: Jenkins
This commit is contained in:
@@ -146,7 +146,7 @@ static OptionInfo const * get_option_info(
|
|||||||
static bool is_option(
|
static bool is_option(
|
||||||
OptionInfo const * option_info, sal_uInt32 * pIndex )
|
OptionInfo const * option_info, sal_uInt32 * pIndex )
|
||||||
{
|
{
|
||||||
OSL_ASSERT( option_info != 0 );
|
assert(option_info != 0);
|
||||||
if (osl_getCommandArgCount() <= *pIndex)
|
if (osl_getCommandArgCount() <= *pIndex)
|
||||||
return false;
|
return false;
|
||||||
|
|
||||||
|
@@ -709,7 +709,9 @@ void HelpLinker::main( std::vector<std::string> &args,
|
|||||||
}
|
}
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{ //called from extension manager
|
{
|
||||||
|
assert(pExtensionPath);
|
||||||
|
//called from extension manager
|
||||||
extensionPath = *pExtensionPath;
|
extensionPath = *pExtensionPath;
|
||||||
sourceRoot = fs::path(extensionPath);
|
sourceRoot = fs::path(extensionPath);
|
||||||
extensionDestination = *pDestination;
|
extensionDestination = *pDestination;
|
||||||
|
@@ -99,9 +99,9 @@ bool SvMetaAttribute::ReadSvIdl( SvIdlDataBase & rBase,
|
|||||||
size_t SvMetaAttribute::MakeSfx( OStringBuffer& rAttrArray ) const
|
size_t SvMetaAttribute::MakeSfx( OStringBuffer& rAttrArray ) const
|
||||||
{
|
{
|
||||||
SvMetaType * pType = GetType();
|
SvMetaType * pType = GetType();
|
||||||
DBG_ASSERT( pType, "no type for attribute" );
|
assert(pType && "no type for attribute");
|
||||||
SvMetaType * pBaseType = pType->GetBaseType();
|
SvMetaType * pBaseType = pType->GetBaseType();
|
||||||
DBG_ASSERT( pBaseType, "no base type for attribute" );
|
assert(pBaseType && "no base type for attribute");
|
||||||
if( pBaseType->GetMetaTypeType() == MetaTypeType::Struct )
|
if( pBaseType->GetMetaTypeType() == MetaTypeType::Struct )
|
||||||
return pBaseType->MakeSfx( rAttrArray );
|
return pBaseType->MakeSfx( rAttrArray );
|
||||||
else
|
else
|
||||||
|
@@ -319,19 +319,16 @@ StorageElementFactory::createStream( const OUString & rUri,
|
|||||||
new Stream( m_xContext, m_xDocsMgr, rUri, xParentStorage, xStream ) );
|
new Stream( m_xContext, m_xDocsMgr, rUri, xParentStorage, xStream ) );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
void StorageElementFactory::releaseElement( Storage const * pElement )
|
void StorageElementFactory::releaseElement( Storage const * pElement )
|
||||||
{
|
{
|
||||||
OSL_ASSERT( pElement );
|
assert(pElement);
|
||||||
osl::MutexGuard aGuard( m_aMutex );
|
osl::MutexGuard aGuard( m_aMutex );
|
||||||
if ( pElement->m_aContainerIt != m_aMap.end() )
|
if ( pElement->m_aContainerIt != m_aMap.end() )
|
||||||
m_aMap.erase( pElement->m_aContainerIt );
|
m_aMap.erase( pElement->m_aContainerIt );
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
// Non-UNO interface
|
// Non-UNO interface
|
||||||
|
|
||||||
|
|
||||||
uno::Reference< embed::XStorage > StorageElementFactory::queryParentStorage(
|
uno::Reference< embed::XStorage > StorageElementFactory::queryParentStorage(
|
||||||
const OUString & rUri, StorageAccessMode eMode )
|
const OUString & rUri, StorageAccessMode eMode )
|
||||||
{
|
{
|
||||||
|
Reference in New Issue
Block a user