From d4df251320ba266ff3fe3da9e3b991c18ea50f5c Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Wed, 12 Aug 2020 11:15:51 +0200 Subject: expand out DELETEZ Change-Id: Ia69fb105c6cc661ac94a360d47655b3faa9d6bb8 Reviewed-on: https://gerrit.libreoffice.org/c/core/+/100618 Tested-by: Jenkins Reviewed-by: Noel Grandin --- sot/source/sdstor/storage.cxx | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) (limited to 'sot') diff --git a/sot/source/sdstor/storage.cxx b/sot/source/sdstor/storage.cxx index f15fb22dd9f1..56ffb92dc108 100644 --- a/sot/source/sdstor/storage.cxx +++ b/sot/source/sdstor/storage.cxx @@ -306,7 +306,10 @@ void SotStorage::CreateStorage( bool bForceUCBStorage, StreamMode nMode ) // check the stream m_pStorStm = ::utl::UcbStreamHelper::CreateStream( m_aName, nMode ).release(); if ( m_pStorStm && m_pStorStm->GetError() ) - DELETEZ( m_pStorStm ); + { + delete m_pStorStm; + m_pStorStm = nullptr; + } if ( m_pStorStm ) { @@ -319,7 +322,8 @@ void SotStorage::CreateStorage( bool bForceUCBStorage, StreamMode nMode ) if ( bIsUCBStorage ) { // UCBStorage always works directly on the UCB content, so discard the stream first - DELETEZ( m_pStorStm ); + delete m_pStorStm; + m_pStorStm = nullptr; m_pOwnStg = new UCBStorage( m_aName, nMode, true, true/*bIsRoot*/ ); } else -- cgit