summaryrefslogtreecommitdiff
path: root/framework/source/uiconfiguration/moduleimagemanager.cxx
diff options
context:
space:
mode:
authorRĂ¼diger Timm <rt@openoffice.org>2007-07-06 11:23:17 +0000
committerRĂ¼diger Timm <rt@openoffice.org>2007-07-06 11:23:17 +0000
commitec3afb4b294417700e25e2d607b21e362d7bff80 (patch)
treee4000047e7ad66bc910447d6366ff53d9b279fa4 /framework/source/uiconfiguration/moduleimagemanager.cxx
parent976fdd72b264fcc2b6f456f4e839d0f6f78bc016 (diff)
INTEGRATION: CWS c09tosrc (1.19.10); FILE MERGED
2007/06/18 15:09:45 cd 1.19.10.1: #i78621# Delete stream object after png reader has been destroyed
Diffstat (limited to 'framework/source/uiconfiguration/moduleimagemanager.cxx')
-rw-r--r--framework/source/uiconfiguration/moduleimagemanager.cxx22
1 files changed, 12 insertions, 10 deletions
diff --git a/framework/source/uiconfiguration/moduleimagemanager.cxx b/framework/source/uiconfiguration/moduleimagemanager.cxx
index 141bd7151d..4f42c8124d 100644
--- a/framework/source/uiconfiguration/moduleimagemanager.cxx
+++ b/framework/source/uiconfiguration/moduleimagemanager.cxx
@@ -4,9 +4,9 @@
*
* $RCSfile: moduleimagemanager.cxx,v $
*
- * $Revision: 1.19 $
+ * $Revision: 1.20 $
*
- * last change: $Author: ihi $ $Date: 2007-06-06 14:02:02 $
+ * last change: $Author: rt $ $Date: 2007-07-06 12:23:17 $
*
* The Contents of this file are made available subject to
* the terms of GNU Lesser General Public License Version 2.1.
@@ -630,12 +630,12 @@ sal_Bool ModuleImageManager::implts_loadUserImages(
if ( xBitmapStream.is() )
{
SvStream* pSvStream( 0 );
- BitmapEx aUserBitmap;
- {
- pSvStream = utl::UcbStreamHelper::CreateStream( xBitmapStream );
- vcl::PNGReader aPngReader( *pSvStream );
- aUserBitmap = aPngReader.Read();
- }
+ BitmapEx aUserBitmap;
+ {
+ pSvStream = utl::UcbStreamHelper::CreateStream( xBitmapStream );
+ vcl::PNGReader aPngReader( *pSvStream );
+ aUserBitmap = aPngReader.Read();
+ }
delete pSvStream;
// Delete old image list and create a new one from the read bitmap
@@ -714,8 +714,10 @@ sal_Bool ModuleImageManager::implts_storeUserImages(
if ( xBitmapStream.is() )
{
SvStream* pSvStream = utl::UcbStreamHelper::CreateStream( xBitmapStream );
- vcl::PNGWriter aPngWriter( pImageList->GetAsHorizontalStrip() );
- aPngWriter.Write( *pSvStream );
+ {
+ vcl::PNGWriter aPngWriter( pImageList->GetAsHorizontalStrip() );
+ aPngWriter.Write( *pSvStream );
+ }
delete pSvStream;
// Commit user bitmaps storage