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

Comment enhancements. Add an ALWAYS macro in fkey.c to indicate a branch

that is always taken.

FossilOrigin-Name: d5b714cffffe588dd4dd10e0b82df8d99657be88
This commit is contained in:
drh
2009-09-24 13:48:10 +00:00
parent 1bea559a94
commit 1f638ceb34
4 changed files with 27 additions and 15 deletions

View File

@@ -846,11 +846,13 @@ static Trigger *fkActionTrigger(
}
sqlite3DbFree(db, aiCol);
/* If pTab->dbMem==0, then the table may be part of a shared-schema.
** Disable the lookaside buffer before allocating space for the
** trigger definition in this case. */
/* In the current implementation, pTab->dbMem==0 for all tables except
** for temporary tables used to describe subqueries. And temporary
** tables do not have foreign key constraints. Hence, pTab->dbMem
** should always be 0 there.
*/
enableLookaside = db->lookaside.bEnabled;
if( pTab->dbMem==0 ){
if( ALWAYS(pTab->dbMem==0) ){
db->lookaside.bEnabled = 0;
}