1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-08 14:02:16 +03:00

When a transaction or savepoint rollback occurs, save the positions of all open read-cursors so that they can be restored following the rollback operation. Cherry-pick of check-in [dd03a2802f3f27]

FossilOrigin-Name: 402780a9c8df9e7ea898bdca49c1191042fe387a
This commit is contained in:
drh
2014-11-13 13:42:39 +00:00
parent 5a2c8c885c
commit 6f9c5669e2
6 changed files with 132 additions and 31 deletions

View File

@@ -2827,8 +2827,9 @@ case OP_Savepoint: {
if( p1==SAVEPOINT_ROLLBACK ){
isSchemaChange = (db->flags & SQLITE_InternChanges)!=0;
for(ii=0; ii<db->nDb; ii++){
sqlite3BtreeTripAllCursors(db->aDb[ii].pBt, SQLITE_ABORT,
rc = sqlite3BtreeTripAllCursors(db->aDb[ii].pBt, SQLITE_ABORT,
isSchemaChange==0);
if( rc!=SQLITE_OK ) goto abort_due_to_error;
}
}else{
isSchemaChange = 0;