From 6245be90aad17b4920525bea08d5718992f56ddd Mon Sep 17 00:00:00 2001 From: Neil Date: Sun, 22 Jun 2014 13:46:50 +1000 Subject: Extra casting to prevent warnings from cppcheck. --- src/PositionCache.cxx | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'src/PositionCache.cxx') diff --git a/src/PositionCache.cxx b/src/PositionCache.cxx index f61999a4b..b81fe5930 100644 --- a/src/PositionCache.cxx +++ b/src/PositionCache.cxx @@ -559,7 +559,7 @@ void PositionCacheEntry::Set(unsigned int styleNumber_, const char *s_, for (unsigned int i=0; i(positions + len), s_, len); + memcpy(reinterpret_cast(reinterpret_cast(positions + len)), s_, len); } } @@ -578,7 +578,7 @@ void PositionCacheEntry::Clear() { bool PositionCacheEntry::Retrieve(unsigned int styleNumber_, const char *s_, unsigned int len_, XYPOSITION *positions_) const { if ((styleNumber == styleNumber_) && (len == len_) && - (memcmp(reinterpret_cast(positions + len), s_, len)== 0)) { + (memcmp(reinterpret_cast(reinterpret_cast(positions + len)), s_, len)== 0)) { for (unsigned int i=0; i