diff options
author | Caolán McNamara <cmc@openoffice.org> | 2009-11-05 14:02:48 +0000 |
---|---|---|
committer | Caolán McNamara <cmc@openoffice.org> | 2009-11-05 14:02:48 +0000 |
commit | 0fd101e7a9bdc3ec07220ff1a02dac94ff0da133 (patch) | |
tree | 65e578f2898f0cc9dda2027373c719b78e675095 | |
parent | 0f1ef6f3d9aa2228e75c7eef260d672e6f1db0e0 (diff) |
cmcfixes65: #i106632# fix memleaks
-rw-r--r-- | hwpfilter/source/hwpreader.cxx | 10 |
1 files changed, 10 insertions, 0 deletions
diff --git a/hwpfilter/source/hwpreader.cxx b/hwpfilter/source/hwpreader.cxx index fc253ed4ce13..f971bedc498a 100644 --- a/hwpfilter/source/hwpreader.cxx +++ b/hwpfilter/source/hwpreader.cxx @@ -4476,10 +4476,20 @@ void HwpReader::makePictureDRAW(HWPDrawingObject *drawobj, Picture * hbox) if( bIsNatural == sal_False ){ PeriodicSpline(n, tarr, xarr, xb, carr, darr); + // prevent memory leak + delete[] carr; + carr = 0; + delete[] darr; + darr = 0; PeriodicSpline(n, tarr, yarr, yb, carr, darr); } else{ NaturalSpline(n, tarr, xarr, xb, carr, darr); + // prevent memory leak + delete[] carr; + carr = 0; + delete[] darr; + darr = 0; NaturalSpline(n, tarr, yarr, yb, carr, darr); } |