summaryrefslogtreecommitdiff
path: root/desktop/source/deployment/dp_persmap.cxx
diff options
context:
space:
mode:
authorStephan Bergmann <sbergman@redhat.com>2018-01-12 20:25:38 +0100
committerStephan Bergmann <sbergman@redhat.com>2018-01-12 20:25:38 +0100
commit029149e9b7aa8ad66dca2972e26385c831153c80 (patch)
treefd5cc80e4372eecd4e9d68b636a39ef406cd286c /desktop/source/deployment/dp_persmap.cxx
parent6e8765b161a1c839fd303eecbd4ddd56f85b86ac (diff)
More loplugin:cstylecast: desktop
auto-rewrite with <https://gerrit.libreoffice.org/#/c/47798/> "Enable loplugin:cstylecast for some more cases" plus solenv/clang-format/reformat-formatted-files Change-Id: I492363d79e443221b139f0c192a552cc5548ee4f
Diffstat (limited to 'desktop/source/deployment/dp_persmap.cxx')
-rw-r--r--desktop/source/deployment/dp_persmap.cxx10
1 files changed, 5 insertions, 5 deletions
diff --git a/desktop/source/deployment/dp_persmap.cxx b/desktop/source/deployment/dp_persmap.cxx
index ac45ea30142d..e254d9b67c0a 100644
--- a/desktop/source/deployment/dp_persmap.cxx
+++ b/desktop/source/deployment/dp_persmap.cxx
@@ -70,7 +70,7 @@ static OString encodeString( const OString& rStr)
// short circuit for the simple non-encoded case
while( --i >= 0)
{
- const unsigned char c = (unsigned char) *(pChar++);
+ const unsigned char c = static_cast<unsigned char>(*(pChar++));
if( c <= 0x0F )
break;
if( c == '%')
@@ -84,7 +84,7 @@ static OString encodeString( const OString& rStr)
aEncStr.append( pChar - (nLen-i), nLen - i);
while( --i >= 0)
{
- unsigned char c = (unsigned char) *(pChar++);
+ unsigned char c = static_cast<unsigned char>(*(pChar++));
if( c <= 0x0F )
{
aEncStr.append( '%');
@@ -173,7 +173,7 @@ void PersistentMap::readAll()
if( nBytesRead != sizeof(aHeaderBytes))
return;
// check header magic
- for( int i = 0; i < (int)sizeof(PmapMagic); ++i)
+ for( int i = 0; i < int(sizeof(PmapMagic)); ++i)
if( aHeaderBytes[i] != PmapMagic[i])
return;
@@ -237,13 +237,13 @@ void PersistentMap::flush()
const OString aKeyString = encodeString( (*it).first);
const sal_Int32 nKeyLen = aKeyString.getLength();
m_MapFile.write( aKeyString.getStr(), nKeyLen, nBytesWritten);
- OSL_ASSERT( nKeyLen == (sal_Int32)nBytesWritten);
+ OSL_ASSERT( nKeyLen == static_cast<sal_Int32>(nBytesWritten));
m_MapFile.write( "\n", 1, nBytesWritten);
// write line for value
const OString& rValString = encodeString( (*it).second);
const sal_Int32 nValLen = rValString.getLength();
m_MapFile.write( rValString.getStr(), nValLen, nBytesWritten);
- OSL_ASSERT( nValLen == (sal_Int32)nBytesWritten);
+ OSL_ASSERT( nValLen == static_cast<sal_Int32>(nBytesWritten));
m_MapFile.write( "\n", 1, nBytesWritten);
}
nullCaolán McNamara 2020-09-17ScCompiler always has a ScDocument&Caolán McNamara 2020-09-17ScCompiler ctors never passed a null ScDocument*Caolán McNamara 2020-09-17base-class formula::FormulaCompiler is sufficient hereCaolán McNamara 2020-09-14ScCompiler::MoveRelWrap never passed a null ScDocument*Caolán McNamara 2020-03-12Revert "loplugin:constfields in sc"Noel Grandin 2020-01-22tdf#83779: convert TRUE/FALSE constants to functions TRUE()/FALSE()Mike Kaganski 2019-12-14sc: rowcol: tdf#50916 convert Valid* methodsNoel Grandin 2019-12-13sc: rowcol: tdf#50916 create ScSheetLimits to hold by rtl::ReferenceNoel Grandin 2019-12-12sc: rowcol: tdf#50916 pass ScDocument to the token classesNoel Grandin 2019-12-05make some classes module privateNoel Grandin 2019-10-29sc: rowcol: tdf#50916 convert core/toolNoel Grandin 2019-09-26loplugin:constmethod in scNoel Grandin 2019-09-01Fix '..'Andrea Gelmini 2019-06-04Resolves: tdf#123752 allow group separator in formula values if possibleEike Rathke 2019-01-10pass ScTokenArray around by unique_ptrNoel Grandin 2018-12-11find-unneeded-includes: Avoid proposing o3tl fw declarationGabor Kelemen 2018-11-08loplugin:constantparamNoel Grandin 2018-10-15loplugin:constfields in scNoel Grandin