diff options
Diffstat (limited to 'sw/source/filter/ww8/ww8par2.cxx')
-rw-r--r-- | sw/source/filter/ww8/ww8par2.cxx | 7 |
1 files changed, 3 insertions, 4 deletions
diff --git a/sw/source/filter/ww8/ww8par2.cxx b/sw/source/filter/ww8/ww8par2.cxx index 4d20e6781628..c1e1cb6c912a 100644 --- a/sw/source/filter/ww8/ww8par2.cxx +++ b/sw/source/filter/ww8/ww8par2.cxx @@ -3614,10 +3614,9 @@ void WW8RStyle::ImportSprms(std::size_t nPosFc, short nLen, bool bPap) if (checkSeek(*pStStrm, nPosFc)) { - sal_uInt8 *pSprms = new sal_uInt8[nLen]; - nLen = pStStrm->ReadBytes(pSprms, nLen); - ImportSprms(pSprms, nLen, bPap); - delete[] pSprms; + std::unique_ptr<sal_uInt8[]> pSprms( new sal_uInt8[nLen] ); + nLen = pStStrm->ReadBytes(pSprms.get(), nLen); + ImportSprms(pSprms.get(), nLen, bPap); } } |