vcl/win/source/gdi/salbmp.cxx |    9 +++++++++
 1 file changed, 9 insertions(+)

New commits:
commit dd1cb9aa9ea24b6c89de05e6c5deae7951b78feb
Author: Armin Le Grand <[email protected]>
Date:   Mon Oct 21 10:33:16 2013 +0000

    i123478 Secure mem freeing for BitmapBuffer class

diff --git a/vcl/win/source/gdi/salbmp.cxx b/vcl/win/source/gdi/salbmp.cxx
index 8040ab4..005f822 100644
--- a/vcl/win/source/gdi/salbmp.cxx
+++ b/vcl/win/source/gdi/salbmp.cxx
@@ -333,6 +333,9 @@ Gdiplus::Bitmap* WinSalBitmap::ImplCreateGdiPlusBitmap()
 
     if(pExtraRGB)
     {
+        // #123478# shockingly, BitmapBuffer does not free the memory it is 
controlling
+        // in it's destructor, this *has to be done handish*. Doing it here now
+        delete[] pExtraRGB->mpBits;
         delete pExtraRGB;
     }
     else
@@ -471,6 +474,9 @@ Gdiplus::Bitmap* 
WinSalBitmap::ImplCreateGdiPlusBitmap(const WinSalBitmap& rAlph
 
     if(pExtraA)
     {
+        // #123478# shockingly, BitmapBuffer does not free the memory it is 
controlling
+        // in it's destructor, this *has to be done handish*. Doing it here now
+        delete[] pExtraA->mpBits;
         delete pExtraA;
     }
     else
@@ -485,6 +491,9 @@ Gdiplus::Bitmap* 
WinSalBitmap::ImplCreateGdiPlusBitmap(const WinSalBitmap& rAlph
 
     if(pExtraRGB)
     {
+        // #123478# shockingly, BitmapBuffer does not free the memory it is 
controlling
+        // in it's destructor, this *has to be done handish*. Doing it here now
+        delete[] pExtraRGB->mpBits;
         delete pExtraRGB;
     }
     else
_______________________________________________
Libreoffice-commits mailing list
[email protected]
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to