diff options
author | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-02-05 14:03:13 +0200 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2019-02-05 14:45:08 +0100 |
commit | 8a7a93b3f24b95bfcffc25e58f9e43c7be4cc1f1 (patch) | |
tree | 651da01917f615025542de018b6c6c92f37a770d /sot/source/sdstor/stgio.cxx | |
parent | 5509d639d0b245415f647690619de5a5163ca620 (diff) |
loplugin:flatten in sot
Change-Id: I66ca5113054862f1549a3d7c27da70cf4f5fc308
Reviewed-on: https://gerrit.libreoffice.org/67403
Tested-by: Jenkins
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sot/source/sdstor/stgio.cxx')
-rw-r--r-- | sot/source/sdstor/stgio.cxx | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/sot/source/sdstor/stgio.cxx b/sot/source/sdstor/stgio.cxx index e41c3d356ce4..2a82c0731b52 100644 --- a/sot/source/sdstor/stgio.cxx +++ b/sot/source/sdstor/stgio.cxx @@ -105,20 +105,20 @@ void StgIo::SetupStreams() m_pFAT = new StgFATStrm(*this, nFatStrmSize); m_pTOC = new StgDirStrm(*this); - if( !GetError() ) + if( GetError() ) + return; + + StgDirEntry* pRoot = m_pTOC->GetRoot(); + if( pRoot ) { - StgDirEntry* pRoot = m_pTOC->GetRoot(); - if( pRoot ) - { - m_pDataFAT = new StgDataStrm( *this, m_aHdr.GetDataFATStart(), -1 ); - m_pDataStrm = new StgDataStrm( *this, *pRoot ); - m_pDataFAT->SetIncrement( 1 << m_aHdr.GetPageSize() ); - m_pDataStrm->SetIncrement( GetDataPageSize() ); - m_pDataStrm->SetEntry( *pRoot ); - } - else - SetError( SVSTREAM_FILEFORMAT_ERROR ); + m_pDataFAT = new StgDataStrm( *this, m_aHdr.GetDataFATStart(), -1 ); + m_pDataStrm = new StgDataStrm( *this, *pRoot ); + m_pDataFAT->SetIncrement( 1 << m_aHdr.GetPageSize() ); + m_pDataStrm->SetIncrement( GetDataPageSize() ); + m_pDataStrm->SetEntry( *pRoot ); } + else + SetError( SVSTREAM_FILEFORMAT_ERROR ); } // get the logical data page size |