From 876413440d051f7bae8b3d222320f4bc3b617b79 Mon Sep 17 00:00:00 2001 From: Stephan Bergmann Date: Sat, 17 Jan 2015 18:16:10 +0100 Subject: Some more loplugin:cstylecast: comphelper Change-Id: I6d3ffb195a7c9a3c44744d296fb9d9eca00115cd --- comphelper/source/misc/docpasswordhelper.cxx | 4 ++-- comphelper/source/misc/evtmethodhelper.cxx | 4 ++-- comphelper/source/misc/storagehelper.cxx | 2 +- 3 files changed, 5 insertions(+), 5 deletions(-) (limited to 'comphelper') diff --git a/comphelper/source/misc/docpasswordhelper.cxx b/comphelper/source/misc/docpasswordhelper.cxx index 4bda261e5611..fdcb8a02993a 100644 --- a/comphelper/source/misc/docpasswordhelper.cxx +++ b/comphelper/source/misc/docpasswordhelper.cxx @@ -288,7 +288,7 @@ Sequence< sal_Int8 > DocPasswordHelper::GetXLHashAsSequence( uno::Sequence< sal_Int8 > aResultKey; if ( aDocId.getLength() == 16 ) - aResultKey = GenerateStd97Key(pPassData, (const sal_uInt8*)aDocId.getConstArray()); + aResultKey = GenerateStd97Key(pPassData, reinterpret_cast(aDocId.getConstArray())); return aResultKey; } @@ -338,7 +338,7 @@ Sequence< sal_Int8 > DocPasswordHelper::GetXLHashAsSequence( // Fill raw digest of above updates aResultKey.realloc( RTL_DIGEST_LENGTH_MD5 ); - rtl_digest_rawMD5 ( hDigest, (sal_uInt8*)aResultKey.getArray(), aResultKey.getLength() ); + rtl_digest_rawMD5 ( hDigest, reinterpret_cast(aResultKey.getArray()), aResultKey.getLength() ); // Erase KeyData array and leave. memset( pKeyData, 0, sizeof(pKeyData) ); diff --git a/comphelper/source/misc/evtmethodhelper.cxx b/comphelper/source/misc/evtmethodhelper.cxx index 2f5cf957e252..01f5d6f65d12 100644 --- a/comphelper/source/misc/evtmethodhelper.cxx +++ b/comphelper/source/misc/evtmethodhelper.cxx @@ -29,7 +29,7 @@ namespace comphelper Sequence< OUString> getEventMethodsForType(const Type& type) { typelib_InterfaceTypeDescription *pType=0; - type.getDescription( (typelib_TypeDescription**)&pType); + type.getDescription(reinterpret_cast(&pType)); if(!pType) return Sequence< OUString>(); @@ -50,7 +50,7 @@ namespace comphelper *pNames = pRealMemberDescription->pMemberName; } } - typelib_typedescription_release( (typelib_TypeDescription *)pType ); + typelib_typedescription_release( &pType->aBase ); return aNames; } diff --git a/comphelper/source/misc/storagehelper.cxx b/comphelper/source/misc/storagehelper.cxx index 2b01808f55d1..03b8ce4c4df5 100644 --- a/comphelper/source/misc/storagehelper.cxx +++ b/comphelper/source/misc/storagehelper.cxx @@ -439,7 +439,7 @@ uno::Sequence< beans::NamedValue > OStorageHelper::CreatePackageEncryptionData( break; } - aEncryptionData[nSha1Ind+nInd].Value <<= uno::Sequence< sal_Int8 >( (sal_Int8*)pBuffer, RTL_DIGEST_LENGTH_SHA1 ); + aEncryptionData[nSha1Ind+nInd].Value <<= uno::Sequence< sal_Int8 >( reinterpret_cast(pBuffer), RTL_DIGEST_LENGTH_SHA1 ); } } -- cgit