svtools/source/contnr/treelist.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-)
New commits: commit 3eba5eb1774ab621a1f0f4dcc7e82cce6c025b0a Author: Caolán McNamara <caol...@redhat.com> Date: Sat Jan 31 21:11:57 2015 +0000 coverity#1267678 this is surely backwards (gold) surely we clone from the source and return the newly created entry. Presumably this doesn't break all the time because aCloneLink is generally set ? coverity#1267678 Resource leak Change-Id: I3e02dfaef371e006f1510b186cdd881c991ef2cf (cherry picked from commit 9f1ecd3ac35f06746fe2a12ca52899f664679de5) Reviewed-on: https://gerrit.libreoffice.org/15022 Tested-by: David Tardon <dtar...@redhat.com> Reviewed-by: David Tardon <dtar...@redhat.com> diff --git a/svtools/source/contnr/treelist.cxx b/svtools/source/contnr/treelist.cxx index 60a8d27..1da2c98 100644 --- a/svtools/source/contnr/treelist.cxx +++ b/svtools/source/contnr/treelist.cxx @@ -355,8 +355,8 @@ SvTreeListEntry* SvTreeList::CloneEntry( SvTreeListEntry* pSource ) const if( aCloneLink.IsSet() ) return reinterpret_cast<SvTreeListEntry*>(aCloneLink.Call( pSource )); SvTreeListEntry* pEntry = CreateEntry(); - pSource->Clone( pEntry ); - return pSource; + pEntry->Clone(pSource); + return pEntry; } SvTreeListEntry* SvTreeList::CreateEntry() const
_______________________________________________ Libreoffice-commits mailing list libreoffice-comm...@lists.freedesktop.org http://lists.freedesktop.org/mailman/listinfo/libreoffice-commits