[Libreoffice-commits] core.git: Branch 'libreoffice-5-3' - editeng/source

Julien Nabet serval2412 at yahoo.fr
Thu May 25 19:45:21 UTC 2017


 editeng/source/editeng/impedit.cxx |    1 +
 editeng/source/editeng/impedit.hxx |    4 ++++
 2 files changed, 5 insertions(+)

New commits:
commit 4b6bc4e012bde5737f279377c8186faf38a888ad
Author: Julien Nabet <serval2412 at yahoo.fr>
Date:   Thu May 18 23:25:32 2017 +0200

    fix gdi resource leak (editeng/impedit)
    
    Change-Id: Ia2d9ad88b5bcc2adf7f28ac7833132c04045d55b
    Reviewed-on: https://gerrit.libreoffice.org/37802
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Caolán McNamara <caolanm at redhat.com>
    Tested-by: Caolán McNamara <caolanm at redhat.com>

diff --git a/editeng/source/editeng/impedit.cxx b/editeng/source/editeng/impedit.cxx
index e4eb6156b27e..f76bd36fecb6 100644
--- a/editeng/source/editeng/impedit.cxx
+++ b/editeng/source/editeng/impedit.cxx
@@ -1728,6 +1728,7 @@ void ImpEditView::dragGestureRecognized(const css::datatransfer::dnd::DragGestur
 
     SolarMutexGuard aVclGuard;
 
+    delete pDragAndDropInfo;
     pDragAndDropInfo = nullptr;
 
     Point aMousePosPixel( rDGE.DragOriginX, rDGE.DragOriginY );
diff --git a/editeng/source/editeng/impedit.hxx b/editeng/source/editeng/impedit.hxx
index 291a95ad572a..84f961823b13 100644
--- a/editeng/source/editeng/impedit.hxx
+++ b/editeng/source/editeng/impedit.hxx
@@ -132,6 +132,10 @@ struct DragAndDropInfo
             bHasValidData = false; bUndoAction = false; bOutlinerMode = false;
             nSensibleRange = 0; nCursorWidth = 0; pField = nullptr; nOutlinerDropDest = 0; bDragAccepted = false;
     }
+    ~DragAndDropInfo()
+    {
+            pBackground.disposeAndClear();
+    }
 };
 
 struct ImplIMEInfos


More information about the Libreoffice-commits mailing list