[Libreoffice-commits] core.git: sw/source

Christian Barth Christian.Barth at zoho.com
Wed Jun 28 07:21:02 UTC 2017


 sw/source/core/view/viewsh.cxx |    3 +--
 1 file changed, 1 insertion(+), 2 deletions(-)

New commits:
commit 89494fc501142f83a4ae387394d939d25252f796
Author: Christian Barth <Christian.Barth at zoho.com>
Date:   Mon Jun 26 21:08:28 2017 +0200

    tdf#107880: Make use of ScopedVclPtr
    
    Make the use of VclPtr<VirtualDevice> exception safe by using
    ScopedVclPtr<VirtualDevice> when disposeAndClear() is called
    in same method.
    
    Change-Id: I684eb7fb92c2bf16c30e74dce8e691dfca1a1f45
    Signed-off-by: Christian Barth <Christian.Barth at zoho.com>
    Reviewed-on: https://gerrit.libreoffice.org/39321
    Tested-by: Jenkins <ci at libreoffice.org>
    Reviewed-by: Noel Grandin <noel.grandin at collabora.co.uk>

diff --git a/sw/source/core/view/viewsh.cxx b/sw/source/core/view/viewsh.cxx
index 7cbcd8b4a689..a763e979ff88 100644
--- a/sw/source/core/view/viewsh.cxx
+++ b/sw/source/core/view/viewsh.cxx
@@ -326,7 +326,7 @@ void SwViewShell::ImplEndAction( const bool bIdleEnd )
 
                 pRegion->Compress();
 
-                VclPtr<VirtualDevice> pVout;
+                ScopedVclPtr<VirtualDevice> pVout;
                 while ( !pRegion->empty() )
                 {
                     SwRect aRect( pRegion->back() );
@@ -420,7 +420,6 @@ void SwViewShell::ImplEndAction( const bool bIdleEnd )
                         lcl_PaintTransparentFormControls(*this, aRect); // i#107365
                 }
 
-                pVout.disposeAndClear();
                 delete pRegion;
                 Imp()->DelRegion();
             }


More information about the Libreoffice-commits mailing list