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

Give the sqlite3 object a pointer to the current Parse so that if an OOM

occurs, it can automatically set the Parse.rc value to SQLITE_NOMEM.  This
avoids a frequent extra test of db.mallocFailed in the innermost parser loop.

FossilOrigin-Name: 5c6638040b3017c6be016441422d965a3ca00dd6ae1f78cadc0b54562978f64e
This commit is contained in:
drh
2019-02-08 14:55:30 +00:00
parent 8851e10017
commit 1cf197583d
5 changed files with 21 additions and 10 deletions

View File

@@ -661,6 +661,9 @@ void sqlite3OomFault(sqlite3 *db){
db->u1.isInterrupted = 1;
}
db->lookaside.bDisable++;
if( db->pParse ){
db->pParse->rc = SQLITE_NOMEM_BKPT;
}
}
}