From 7d6e159df4c28afde2fff5bd734ec3a8f63cb15a Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Caol=C3=A1n=20McNamara?= Date: Fri, 16 May 2014 16:06:10 +0100 Subject: [PATCH] fix memory leak on pasting metafiles into writer copying from mspaint to writer and then deleting the image in a loop will eventually exhaust all memory. regression since 004a29b9ac66f68af5ea12a2303a4b2be77d8145 Change-Id: I381285cda3823de7df0c1725a339943caf9536fe --- svtools/source/graphic/grfcache.cxx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/svtools/source/graphic/grfcache.cxx b/svtools/source/graphic/grfcache.cxx index 26d766af354c..72fdc3a6ec9a 100644 --- a/svtools/source/graphic/grfcache.cxx +++ b/svtools/source/graphic/grfcache.cxx @@ -367,7 +367,7 @@ void GraphicCacheEntry::GraphicObjectWasSwappedOut( const GraphicObject& /*rObj* if( mbSwappedAll ) { delete mpBmpEx, mpBmpEx = NULL; - mpMtf = NULL; // No need to delete it as it has already been dereferenced + delete mpMtf, mpMtf = NULL; delete mpAnimation, mpAnimation = NULL; // #119176# also reset SvgData