Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Immediately liberate connection of expression value gatherer
  • Loading branch information
github-actions[bot] authored and nyalldawson committed Jul 2, 2020
1 parent be4820f commit c84ecac
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/core/qgsfeatureexpressionvaluesgatherer.h
Expand Up @@ -91,7 +91,7 @@ class QgsFeatureExpressionValuesGatherer: public QThread
{
mWasCanceled = false;

mIterator = mSource->getFeatures( mRequest );
QgsFeatureIterator iterator = mSource->getFeatures( mRequest );

mDisplayExpression.prepare( &mExpressionContext );

Expand All @@ -100,7 +100,7 @@ class QgsFeatureExpressionValuesGatherer: public QThread
for ( const QString &fieldName : qgis::as_const( mIdentifierFields ) )
attributeIndexes << mSource->fields().indexOf( fieldName );

while ( mIterator.nextFeature( feature ) )
while ( iterator.nextFeature( feature ) )
{
mExpressionContext.setFeature( feature );
QVariantList attributes;
Expand Down Expand Up @@ -165,7 +165,6 @@ class QgsFeatureExpressionValuesGatherer: public QThread
QgsExpression mDisplayExpression;
QgsExpressionContext mExpressionContext;
QgsFeatureRequest mRequest;
QgsFeatureIterator mIterator;
bool mWasCanceled = false;
mutable QMutex mCancelMutex;
QStringList mIdentifierFields;
Expand Down

0 comments on commit c84ecac

Please sign in to comment.