diff options
author | Stephan Bergmann <sbergman@redhat.com> | 2015-03-28 19:07:30 +0100 |
---|---|---|
committer | Stephan Bergmann <sbergman@redhat.com> | 2015-03-28 19:09:26 +0100 |
commit | 8c8d955998a64c8de7fb7dc81035b8889fdfe2e2 (patch) | |
tree | 879d0fa228e11ed3a2e3a6a1151d5e5fcce49454 /svtools/source/svrtf | |
parent | 09757afd363d9d015c42db43dbe93be393d667ee (diff) |
Clean up C-style casts from pointers to void
Change-Id: If8783896136470a0664f1cbac061e30576ef96a4
Diffstat (limited to 'svtools/source/svrtf')
-rw-r--r-- | svtools/source/svrtf/rtfkeywd.cxx | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/svtools/source/svrtf/rtfkeywd.cxx b/svtools/source/svrtf/rtfkeywd.cxx index 164cfb55a1c0..71af7e8c4fd0 100644 --- a/svtools/source/svrtf/rtfkeywd.cxx +++ b/svtools/source/svrtf/rtfkeywd.cxx @@ -1179,25 +1179,25 @@ extern "C" { static int SAL_CALL RTFKeyCompare( const void *pFirst, const void *pSecond) { int nRet = 0; - if( -1 == ((RTF_TokenEntry*)pFirst)->nToken ) + if( -1 == static_cast<RTF_TokenEntry const *>(pFirst)->nToken ) { - if( -1 == ((RTF_TokenEntry*)pSecond)->nToken ) - nRet = ((RTF_TokenEntry*)pFirst)->pUToken->compareTo( - *((RTF_TokenEntry*)pSecond)->pUToken ); + if( -1 == static_cast<RTF_TokenEntry const *>(pSecond)->nToken ) + nRet = static_cast<RTF_TokenEntry const *>(pFirst)->pUToken->compareTo( + *static_cast<RTF_TokenEntry const *>(pSecond)->pUToken ); else { - nRet = ((RTF_TokenEntry*)pFirst)->pUToken->compareToIgnoreAsciiCaseAscii( - ((RTF_TokenEntry*)pSecond)->sToken ); + nRet = static_cast<RTF_TokenEntry const *>(pFirst)->pUToken->compareToIgnoreAsciiCaseAscii( + static_cast<RTF_TokenEntry const *>(pSecond)->sToken ); } } else { - if( -1 == ((RTF_TokenEntry*)pSecond)->nToken ) - nRet = -1 * ((RTF_TokenEntry*)pSecond)->pUToken->compareToIgnoreAsciiCaseAscii( - ((RTF_TokenEntry*)pFirst)->sToken ); + if( -1 == static_cast<RTF_TokenEntry const *>(pSecond)->nToken ) + nRet = -1 * static_cast<RTF_TokenEntry const *>(pSecond)->pUToken->compareToIgnoreAsciiCaseAscii( + static_cast<RTF_TokenEntry const *>(pFirst)->sToken ); else - nRet = strcmp( ((RTF_TokenEntry*)pFirst)->sToken, - ((RTF_TokenEntry*)pSecond)->sToken ); + nRet = strcmp( static_cast<RTF_TokenEntry const *>(pFirst)->sToken, + static_cast<RTF_TokenEntry const *>(pSecond)->sToken ); } return nRet; @@ -1227,7 +1227,7 @@ int GetRTFToken( const OUString& rSearch ) sizeof( aRTFTokenTab ) / sizeof( RTF_TokenEntry ), sizeof( RTF_TokenEntry ), RTFKeyCompare ))) - nRet = ((RTF_TokenEntry*)pFound)->nToken; + nRet = static_cast<RTF_TokenEntry*>(pFound)->nToken; return nRet; } |