diff options
author | Mark Page <aptitude@btconnect.com> | 2016-12-05 14:03:12 +0000 |
---|---|---|
committer | Noel Grandin <noel.grandin@collabora.co.uk> | 2016-12-06 18:17:56 +0000 |
commit | d08db164dcac8f6aa88158b2848abb5ad66a4052 (patch) | |
tree | bacb0e7b183115e3b00bd4c375b37908264f0f87 /sc | |
parent | 0c6c37cb01c242ad9324bc91ac15c974529086c5 (diff) |
Change Read/Write access to Scoped Read/Write access
Change-Id: Idbe8e393b64f2a151e20c1851d7c14fa161acf97
Reviewed-on: https://gerrit.libreoffice.org/31635
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Noel Grandin <noel.grandin@collabora.co.uk>
Diffstat (limited to 'sc')
-rw-r--r-- | sc/source/filter/excel/xeescher.cxx | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/sc/source/filter/excel/xeescher.cxx b/sc/source/filter/excel/xeescher.cxx index c5a66a5a2e5b..5ceb584dc15c 100644 --- a/sc/source/filter/excel/xeescher.cxx +++ b/sc/source/filter/excel/xeescher.cxx @@ -402,7 +402,8 @@ void XclExpImgData::Save( XclExpStream& rStrm ) if( aBmp.GetBitCount() != 24 ) aBmp.Convert( BMP_CONVERSION_24BIT ); - if( BitmapReadAccess* pAccess = aBmp.AcquireReadAccess() ) + Bitmap::ScopedReadAccess pAccess(aBmp); + if( pAccess ) { sal_Int32 nWidth = ::std::min< sal_Int32 >( pAccess->Width(), 0xFFFF ); sal_Int32 nHeight = ::std::min< sal_Int32 >( pAccess->Height(), 0xFFFF ); @@ -434,7 +435,6 @@ void XclExpImgData::Save( XclExpStream& rStrm ) rStrm.EndRecord(); } - Bitmap::ReleaseAccess( pAccess ); } } |