From d51db77c8d87f210785a8a8c6dd875f7bacddb3c Mon Sep 17 00:00:00 2001 From: Mike Kaganski Date: Tue, 15 Oct 2019 01:57:12 +0300 Subject: Remove some memset calls Replace them with default initialization or calloc Change-Id: I747f53c2ced2d0473fd5a5ede4f8520a0633dcc1 Reviewed-on: https://gerrit.libreoffice.org/80805 Tested-by: Jenkins Reviewed-by: Stephan Bergmann --- sc/source/filter/excel/xeroot.cxx | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) (limited to 'sc/source/filter/excel') diff --git a/sc/source/filter/excel/xeroot.cxx b/sc/source/filter/excel/xeroot.cxx index 4268bbd97830..15082d46a226 100644 --- a/sc/source/filter/excel/xeroot.cxx +++ b/sc/source/filter/excel/xeroot.cxx @@ -317,8 +317,7 @@ uno::Sequence< beans::NamedValue > XclExpRoot::GenerateEncryptionData( const OUS rtl_random_destroyPool( aRandomPool ); - sal_uInt16 pnPasswd[16]; - memset( pnPasswd, 0, sizeof( pnPasswd ) ); + sal_uInt16 pnPasswd[16] = {}; for( sal_Int32 nChar = 0; nChar < aPass.getLength(); ++nChar ) pnPasswd[nChar] = aPass[nChar]; -- cgit