diff --git a/src/dict/bgl.cc b/src/dict/bgl.cc index 0dc1734b..57c209c7 100644 --- a/src/dict/bgl.cc +++ b/src/dict/bgl.cc @@ -721,8 +721,8 @@ void BglArticleRequest::run() string const & targetHeadword = displayedHeadword.size() ? displayedHeadword : headword; QCryptographicHash hash( QCryptographicHash::Md5 ); - hash.addData( targetHeadword.data(), targetHeadword.size() + 1 ); // with 0 - hash.addData( articleText.data(), articleText.size() ); + hash.addData( { targetHeadword.data(), static_cast< qsizetype >( targetHeadword.size() + 1 ) } ); // with 0 + hash.addData( { articleText.data(), static_cast< qsizetype >( articleText.size() ) } ); if ( !articleBodiesIncluded.insert( hash.result() ).second ) { continue; // Already had this body diff --git a/src/dict/mdx.cc b/src/dict/mdx.cc index 11b6a7db..aa374cca 100644 --- a/src/dict/mdx.cc +++ b/src/dict/mdx.cc @@ -621,7 +621,7 @@ void MdxArticleRequest::run() } QCryptographicHash hash( QCryptographicHash::Md5 ); - hash.addData( articleBody.data(), articleBody.size() ); + hash.addData( { articleBody.data(), static_cast< qsizetype >( articleBody.length() ) } ); if ( !articleBodiesIncluded.insert( hash.result() ).second ) { continue; // Already had this body }