Skip to content
Permalink
Browse files

Avoid double db close in offline editing plugin

(cherry-picked from 5a8619d)
  • Loading branch information
nyalldawson committed Jul 16, 2018
1 parent a6cd87d commit 4c3174c881120e9fa23f57759ca4d7fe325821fa
Showing with 0 additions and 7 deletions.
  1. +0 −7 src/core/qgsofflineediting.cpp
@@ -1276,7 +1276,6 @@ void QgsOfflineEditing::committedAttributesAdded( const QString &qgisLayerId, co
}

increaseCommitNo( database.get() );
sqlite3_close( database.get() );
}

void QgsOfflineEditing::committedFeaturesAdded( const QString &qgisLayerId, const QgsFeatureList &addedFeatures )
@@ -1302,8 +1301,6 @@ void QgsOfflineEditing::committedFeaturesAdded( const QString &qgisLayerId, cons
.arg( newFeatureIds.at( i ) );
sqlExec( database.get(), sql );
}

sqlite3_close( database.get() );
}

void QgsOfflineEditing::committedFeaturesRemoved( const QString &qgisLayerId, const QgsFeatureIds &deletedFeatureIds )
@@ -1331,8 +1328,6 @@ void QgsOfflineEditing::committedFeaturesRemoved( const QString &qgisLayerId, co
sqlExec( database.get(), sql );
}
}

sqlite3_close( database.get() );
}

void QgsOfflineEditing::committedAttributeValuesChanges( const QString &qgisLayerId, const QgsChangedAttributesMap &changedAttrsMap )
@@ -1367,7 +1362,6 @@ void QgsOfflineEditing::committedAttributeValuesChanges( const QString &qgisLaye
}

increaseCommitNo( database.get() );
sqlite3_close( database.get() );
}

void QgsOfflineEditing::committedGeometriesChanges( const QString &qgisLayerId, const QgsGeometryMap &changedGeometries )
@@ -1400,7 +1394,6 @@ void QgsOfflineEditing::committedGeometriesChanges( const QString &qgisLayerId,
}

increaseCommitNo( database.get() );
sqlite3_close( database.get() );
}

void QgsOfflineEditing::startListenFeatureChanges()

0 comments on commit 4c3174c

Please sign in to comment.
You can’t perform that action at this time.