Skip to content

Commit 7cd8e38

Browse files
committedNov 19, 2017
Fix unnecessarily fussy close() for QgsMsSqlFeatureIterator
1 parent 6f3ebde commit 7cd8e38

File tree

1 file changed

+1
-7
lines changed

1 file changed

+1
-7
lines changed
 

‎src/providers/mssql/qgsmssqlfeatureiterator.cpp

Lines changed: 1 addition & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -425,14 +425,8 @@ bool QgsMssqlFeatureIterator::close()
425425
if ( mClosed )
426426
return false;
427427

428-
if ( mQuery )
428+
if ( mQuery && mQuery->isActive() )
429429
{
430-
if ( !mQuery->isActive() )
431-
{
432-
QgsDebugMsg( "QgsMssqlFeatureIterator::close on inactive query" );
433-
return false;
434-
}
435-
436430
mQuery->finish();
437431
}
438432

0 commit comments

Comments
 (0)
Please sign in to comment.