[Libreoffice-commits] core.git: svx/source
Takeshi Abe
tabe at fixedpoint.jp
Wed Jul 2 06:04:50 PDT 2014
svx/source/table/tablecolumn.cxx | 4 ++++
svx/source/table/tablerow.cxx | 4 ++++
2 files changed, 8 insertions(+)
New commits:
commit b7075e97a4323671fccfd581a9606b1f1ed4b103
Author: Takeshi Abe <tabe at fixedpoint.jp>
Date: Mon Jun 30 18:17:06 2014 +0900
Do not leave unreachable TableColumnUndo/TableRowUndo in case of exceptions
... which might be a memory leak otherwise.
Change-Id: I5e911ba815c3df519365236043fccc7ff21c60b4
Reviewed-on: https://gerrit.libreoffice.org/9979
Reviewed-by: Caolán McNamara <caolanm at redhat.com>
Tested-by: Caolán McNamara <caolanm at redhat.com>
diff --git a/svx/source/table/tablecolumn.cxx b/svx/source/table/tablecolumn.cxx
index 2909f3e..1b0aa17 100644
--- a/svx/source/table/tablecolumn.cxx
+++ b/svx/source/table/tablecolumn.cxx
@@ -209,10 +209,14 @@ void SAL_CALL TableColumn::setFastPropertyValue( sal_Int32 nHandle, const Any& a
break;
}
default:
+ delete pUndo;
throw UnknownPropertyException();
}
if( !bOk )
+ {
+ delete pUndo;
throw IllegalArgumentException();
+ }
if( bChange )
{
diff --git a/svx/source/table/tablerow.cxx b/svx/source/table/tablerow.cxx
index c213e49..d7449ba 100644
--- a/svx/source/table/tablerow.cxx
+++ b/svx/source/table/tablerow.cxx
@@ -283,10 +283,14 @@ void SAL_CALL TableRow::setFastPropertyValue( sal_Int32 nHandle, const Any& aVal
break;
}
default:
+ delete pUndo;
throw UnknownPropertyException();
}
if( !bOk )
+ {
+ delete pUndo;
throw IllegalArgumentException();
+ }
if( bChange )
{
More information about the Libreoffice-commits
mailing list