summaryrefslogtreecommitdiff
path: root/sc
diff options
context:
space:
mode:
Diffstat (limited to 'sc')
-rw-r--r--sc/source/core/data/column.cxx2
-rw-r--r--sc/source/core/data/documen3.cxx3
-rw-r--r--sc/source/core/data/table4.cxx3
3 files changed, 3 insertions, 5 deletions
diff --git a/sc/source/core/data/column.cxx b/sc/source/core/data/column.cxx
index 6c1c8499d5de..50f0e95b153d 100644
--- a/sc/source/core/data/column.cxx
+++ b/sc/source/core/data/column.cxx
@@ -93,7 +93,7 @@ ScColumn::ScColumn() :
ScColumn::~ScColumn()
{
FreeAll();
- if (pAttrArray) delete pAttrArray;
+ delete pAttrArray;
}
diff --git a/sc/source/core/data/documen3.cxx b/sc/source/core/data/documen3.cxx
index 66973deed196..991eb6b48a8e 100644
--- a/sc/source/core/data/documen3.cxx
+++ b/sc/source/core/data/documen3.cxx
@@ -273,8 +273,7 @@ void ScDocument::SetDBCollection( ScDBCollection* pNewDBCollection, bool bRemove
}
}
- if (pDBCollection)
- delete pDBCollection;
+ delete pDBCollection;
pDBCollection = pNewDBCollection;
}
diff --git a/sc/source/core/data/table4.cxx b/sc/source/core/data/table4.cxx
index bc99c5ca03c3..dac41110b777 100644
--- a/sc/source/core/data/table4.cxx
+++ b/sc/source/core/data/table4.cxx
@@ -564,8 +564,7 @@ void ScTable::FillAuto( SCCOL nCol1, SCROW nRow1, SCCOL nCol2, SCROW nRow2,
{
if ( bGetPattern )
{
- if ( pNewPattern )
- delete pNewPattern;
+ delete pNewPattern;
if (bVertical) // rInner&:=nRow, rOuter&:=nCol
pSrcPattern = aCol[nCol].GetPattern(static_cast<SCROW>(nAtSrc));
else // rInner&:=nCol, rOuter&:=nRow