Skip to content

Commit

Permalink
remove unlock from terminated/completed
Browse files Browse the repository at this point in the history
  • Loading branch information
troopa81 authored and nyalldawson committed Mar 20, 2020
1 parent e91cac0 commit 722a41e
Showing 1 changed file with 1 addition and 3 deletions.
4 changes: 1 addition & 3 deletions src/core/qgstaskmanager.cpp
Expand Up @@ -58,7 +58,7 @@ qint64 QgsTask::elapsedTime() const

void QgsTask::start()
{
mNotFinishedMutex.lock();
QMutexLocker locker( &mNotFinishedMutex );
mNotStartedMutex.release();
mStartCount++;
Q_ASSERT( mStartCount == 1 );
Expand Down Expand Up @@ -256,7 +256,6 @@ void QgsTask::completed()
{
mStatus = Complete;
QMetaObject::invokeMethod( this, &QgsTask::processSubTasksForCompletion, Qt::AutoConnection );
mNotFinishedMutex.unlock();
}

void QgsTask::processSubTasksForCompletion()
Expand Down Expand Up @@ -343,7 +342,6 @@ void QgsTask::terminated()
{
mStatus = Terminated;
QMetaObject::invokeMethod( this, &QgsTask::processSubTasksForTermination, Qt::AutoConnection );
mNotFinishedMutex.unlock();
}


Expand Down

0 comments on commit 722a41e

Please sign in to comment.