sdext/source/pdfimport/tree/genericelements.cxx    |    1 -
 sdext/source/pdfimport/tree/writertreevisiting.cxx |    2 --
 2 files changed, 3 deletions(-)

New commits:
commit 4964cb80ec603a1ce9937f230fc6ed6b761a6e1f
Author: Julien Nabet <serval2...@yahoo.fr>
Date:   Tue Jun 26 20:10:20 2018 +0200

    tdf#118374: fix crash from loplugin:useuniqueptr in sdext
    
    See bt:
    https://bugs.documentfoundation.org/attachment.cgi?id=143105
    
    Regression from:
    
https://cgit.freedesktop.org/libreoffice/core/commit/?id=a9ef943769b06e6bdffe7326f288b27e08a95698
    
    Change-Id: I285f00cb6ede3d952a794b60ff64586fe2224e5f
    Reviewed-on: https://gerrit.libreoffice.org/56490
    Reviewed-by: Noel Grandin <noel.gran...@collabora.co.uk>
    Tested-by: Jenkins
    Reviewed-by: Julien Nabet <serval2...@yahoo.fr>

diff --git a/sdext/source/pdfimport/tree/genericelements.cxx 
b/sdext/source/pdfimport/tree/genericelements.cxx
index 8fa84c64c414..0b7177561b6e 100644
--- a/sdext/source/pdfimport/tree/genericelements.cxx
+++ b/sdext/source/pdfimport/tree/genericelements.cxx
@@ -447,7 +447,6 @@ void PageElement::resolveUnderlines( PDFIProcessor const & 
rProc )
             auto next_it = poly_it;
             ++next_it;
             Children.erase( poly_it );
-            delete pPoly;
             poly_it = next_it;
         }
         else
diff --git a/sdext/source/pdfimport/tree/writertreevisiting.cxx 
b/sdext/source/pdfimport/tree/writertreevisiting.cxx
index e66a5fea81a9..f6f6c492f240 100644
--- a/sdext/source/pdfimport/tree/writertreevisiting.cxx
+++ b/sdext/source/pdfimport/tree/writertreevisiting.cxx
@@ -419,7 +419,6 @@ void WriterXmlOptimizer::visit( PolyPolyElement& elem, 
const std::list< std::uni
 #else
         elem.Parent->Children.erase(next_it);
 #endif
-        delete pNext;
     }
 }
 
@@ -819,7 +818,6 @@ void WriterXmlOptimizer::optimizeTextElements(Element& 
rParent)
                     pCur->Children.splice( pCur->Children.end(), 
pNext->Children );
                     // get rid of the now useless element
                     rParent.Children.erase( next );
-                    delete pNext;
                     bConcat = true;
                 }
             }
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
https://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to