diff options
author | Caolán McNamara <caolanm@redhat.com> | 2012-01-22 22:59:09 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2012-01-23 11:37:06 +0000 |
commit | 2563c8dd790f26909f9f15fd29b900ebfbc7e467 (patch) | |
tree | b26b3eb71d5b809b699bbac81aef6b8e49fb5dc9 /svl | |
parent | b1f74de0311af25596e861c24be8b829f4b27cb4 (diff) |
can't see the point of calling String::Erase before delete String
Diffstat (limited to 'svl')
-rw-r--r-- | svl/source/numbers/zformat.cxx | 10 |
1 files changed, 3 insertions, 7 deletions
diff --git a/svl/source/numbers/zformat.cxx b/svl/source/numbers/zformat.cxx index 06c70b888a87..d2c3e901a449 100644 --- a/svl/source/numbers/zformat.cxx +++ b/svl/source/numbers/zformat.cxx @@ -137,7 +137,7 @@ const sal_uInt16 nNewStandardFlagVersionId = 0x4653; // "SF" void ImpSvNumberformatInfo::Copy( const ImpSvNumberformatInfo& rNumFor, sal_uInt16 nAnz ) { - for (sal_uInt16 i = 0; i < nAnz; i++) + for (sal_uInt16 i = 0; i < nAnz; ++i) { sStrArray[i] = rNumFor.sStrArray[i]; nTypeArray[i] = rNumFor.nTypeArray[i]; @@ -348,8 +348,6 @@ ImpSvNumFor::ImpSvNumFor() ImpSvNumFor::~ImpSvNumFor() { - for (sal_uInt16 i = 0; i < nAnzStrings; i++) - aI.sStrArray[i].Erase(); delete [] aI.sStrArray; delete [] aI.nTypeArray; } @@ -358,10 +356,8 @@ void ImpSvNumFor::Enlarge(sal_uInt16 nAnz) { if ( nAnzStrings != nAnz ) { - if ( aI.nTypeArray ) - delete [] aI.nTypeArray; - if ( aI.sStrArray ) - delete [] aI.sStrArray; + delete [] aI.nTypeArray; + delete [] aI.sStrArray; nAnzStrings = nAnz; if ( nAnz ) { |