mirror of
https://github.com/tomahawk-player/tomahawk.git
synced 2025-08-06 14:16:32 +02:00
Delete lister after it's done, before returning
This commit is contained in:
@@ -283,6 +283,16 @@ MusicScanner::listerFinished( const QMap<QString, unsigned int>& newmtimes )
|
|||||||
connect( cmd, SIGNAL( finished() ), SIGNAL( finished() ) );
|
connect( cmd, SIGNAL( finished() ), SIGNAL( finished() ) );
|
||||||
|
|
||||||
Database::instance()->enqueue( QSharedPointer<DatabaseCommand>(cmd) );
|
Database::instance()->enqueue( QSharedPointer<DatabaseCommand>(cmd) );
|
||||||
|
|
||||||
|
if ( !m_dirLister.isNull() )
|
||||||
|
{
|
||||||
|
m_dirListerThreadController->quit();;
|
||||||
|
m_dirListerThreadController->wait( 60000 );
|
||||||
|
|
||||||
|
delete m_dirLister.data();
|
||||||
|
delete m_dirListerThreadController;
|
||||||
|
m_dirListerThreadController = 0;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user