sw/source/core/doc/doctxm.cxx |    1 +
 1 file changed, 1 insertion(+)

New commits:
commit e4e9768e43b9c435036a0f0f3446688c9a5b8375
Author: Mark Wielaard <m...@klomp.org>
Date:   Sun Jun 23 22:48:39 2013 +0200

    Fix memory leak in SwTOXBaseSection::GenerateText.
    
    Delete LinkStruct created in TOKEN_LINK_END case after copying contents.
    
    Change-Id: I294009ad62756996cf840ebf56b28d79dfd6e2f3
    Reviewed-on: https://gerrit.libreoffice.org/4470
    Reviewed-by: Michael Stahl <mst...@redhat.com>
    Tested-by: Michael Stahl <mst...@redhat.com>

diff --git a/sw/source/core/doc/doctxm.cxx b/sw/source/core/doc/doctxm.cxx
index 02bc7de..e0157ff 100644
--- a/sw/source/core/doc/doctxm.cxx
+++ b/sw/source/core/doc/doctxm.cxx
@@ -1837,6 +1837,7 @@ void SwTOXBaseSection::GenerateText( sal_uInt16 nArrayIdx,
     {
         pTOXNd->InsertItem((*i)->aINetFmt, (*i)->nStartTextPos,
                            (*i)->nEndTextPos);
+        delete (*i);
     }
 }
 
_______________________________________________
Libreoffice-commits mailing list
libreoffice-comm...@lists.freedesktop.org
http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits

Reply via email to