aboutsummaryrefslogtreecommitdiff
path: root/src/tokenize.c
diff options
context:
space:
mode:
authordrh <drh@noemail.net>2009-06-23 20:28:53 +0000
committerdrh <drh@noemail.net>2009-06-23 20:28:53 +0000
commit0b9f50d8aa4fb27d6f514efa9badc6b92045a862 (patch)
tree032eecb27e24be02f6919c89b6470474a6190407 /src/tokenize.c
parent1c3d2bf9cf3df965835cf8916b1331bcdac0705b (diff)
downloadsqlite-0b9f50d8aa4fb27d6f514efa9badc6b92045a862.tar.gz
sqlite-0b9f50d8aa4fb27d6f514efa9badc6b92045a862.zip
Enhance autoincrement so that it works with triggers that also do
autoincrement inserts, even multiple inserts into the same table. Ticket #3928 (CVS 6807) FossilOrigin-Name: 1330993de8eae7baeec24100216158063c9bdc19
Diffstat (limited to 'src/tokenize.c')
-rw-r--r--src/tokenize.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/src/tokenize.c b/src/tokenize.c
index 6761f8c3c..3fdb38ede 100644
--- a/src/tokenize.c
+++ b/src/tokenize.c
@@ -15,7 +15,7 @@
** individual tokens and sends those tokens one-by-one over to the
** parser for analysis.
**
-** $Id: tokenize.c,v 1.161 2009/06/17 01:17:13 drh Exp $
+** $Id: tokenize.c,v 1.162 2009/06/23 20:28:54 drh Exp $
*/
#include "sqliteInt.h"
#include <stdlib.h>
@@ -518,6 +518,11 @@ abort_parse:
sqlite3DeleteTrigger(db, pParse->pNewTrigger);
sqlite3DbFree(db, pParse->apVarExpr);
sqlite3DbFree(db, pParse->aAlias);
+ while( pParse->pAinc ){
+ AutoincInfo *p = pParse->pAinc;
+ pParse->pAinc = p->pNext;
+ sqlite3DbFree(db, p);
+ }
while( pParse->pZombieTab ){
Table *p = pParse->pZombieTab;
pParse->pZombieTab = p->pNextZombie;