fix: mdd resource files spread across multi blocks .

https://github.com/goldendict/goldendict/pull/1400#issuecomment-1008965814
This commit is contained in:
xiaoyifang 2022-01-10 23:42:27 +08:00
parent 5e817e7d40
commit b163064f86

View file

@ -584,7 +584,7 @@ bool MdictParser::readRecordBlock( MdictParser::HeadWordIndex & headWordIndex,
for ( HeadWordIndex::const_iterator i = headWordIndex.begin(); i != headWordIndex.end(); ++i )
{
if ( recordBlockInfos_[idx].endPos <= i->first )
if (recordBlockInfos_[idx].shadowEndPos <= i->first)
idx = RecordIndex::bsearch( recordBlockInfos_, i->first );
if ( idx == ( size_t )( -1 ) )