mirror of
https://github.com/xiaoyifang/goldendict-ng.git
synced 2024-11-27 23:34:06 +00:00
Fix removing of unused FTS index files in some special cases
This commit is contained in:
parent
488286a75f
commit
816e523fae
|
@ -348,12 +348,14 @@ void loadDictionaries( QWidget * parent, bool showInitially,
|
|||
for( QStringList::const_iterator i = allIdxFiles.constBegin();
|
||||
i != allIdxFiles.constEnd(); ++i )
|
||||
{
|
||||
if ( ids.find( FsEncoding::encode( *i ) ) == ids.end() &&
|
||||
i->size() == 32 )
|
||||
{
|
||||
if ( ids.find( FsEncoding::encode( *i ) ) == ids.end()
|
||||
&& i->size() == 32 )
|
||||
indexDir.remove( *i );
|
||||
else
|
||||
if ( i->endsWith( "_FTS" )
|
||||
&& i->size() == 36
|
||||
&& ids.find( FsEncoding::encode( i->left( 32 ) ) ) == ids.end() )
|
||||
indexDir.remove( *i );
|
||||
indexDir.remove( *i + "_FTS" );
|
||||
}
|
||||
}
|
||||
|
||||
// Run deferred inits
|
||||
|
|
Loading…
Reference in a new issue