aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/sqliteInt.h4
-rw-r--r--src/tclsqlite.c3
-rw-r--r--src/tokenize.c4
3 files changed, 5 insertions, 6 deletions
diff --git a/src/sqliteInt.h b/src/sqliteInt.h
index 304697e51..8420425a5 100644
--- a/src/sqliteInt.h
+++ b/src/sqliteInt.h
@@ -11,7 +11,7 @@
*************************************************************************
** Internal interface definitions for SQLite.
**
-** @(#) $Id: sqliteInt.h,v 1.891 2009/07/03 15:37:28 drh Exp $
+** @(#) $Id: sqliteInt.h,v 1.892 2009/07/03 22:54:37 drh Exp $
*/
#ifndef _SQLITEINT_H_
#define _SQLITEINT_H_
@@ -2020,10 +2020,8 @@ struct Parse {
int nAliasAlloc; /* Number of allocated slots for aAlias[] */
int *aAlias; /* Register used to hold aliased result */
u8 explain; /* True if the EXPLAIN flag is found on the query */
- Token sErrToken; /* The token at which the error occurred */
Token sNameToken; /* Token with unqualified schema object name */
Token sLastToken; /* The last token parsed */
- const char *zSql; /* All SQL text */
const char *zTail; /* All SQL text past the last semicolon parsed */
Table *pNewTable; /* A table being constructed by CREATE TABLE */
Trigger *pNewTrigger; /* Trigger under construct by a CREATE TRIGGER */
diff --git a/src/tclsqlite.c b/src/tclsqlite.c
index 4c6c5fc31..d353fc3dd 100644
--- a/src/tclsqlite.c
+++ b/src/tclsqlite.c
@@ -12,7 +12,7 @@
** A TCL Interface to SQLite. Append this file to sqlite3.c and
** compile the whole thing to build a TCL-enabled version of SQLite.
**
-** $Id: tclsqlite.c,v 1.241 2009/03/27 12:44:35 drh Exp $
+** $Id: tclsqlite.c,v 1.242 2009/07/03 22:54:37 drh Exp $
*/
#include "tcl.h"
#include <errno.h>
@@ -1674,6 +1674,7 @@ static int DbObjCmd(void *cd, Tcl_Interp *interp, int objc,Tcl_Obj *const*objv){
** which matches the next sequence of SQL.
*/
pStmt = 0;
+ while( isspace(zSql[0]) ){ zSql++; }
len = strlen30(zSql);
for(pPreStmt = pDb->stmtList; pPreStmt; pPreStmt=pPreStmt->pNext){
int n = pPreStmt->nSql;
diff --git a/src/tokenize.c b/src/tokenize.c
index 3fdb38ede..97c4b7b59 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.162 2009/06/23 20:28:54 drh Exp $
+** $Id: tokenize.c,v 1.163 2009/07/03 22:54:37 drh Exp $
*/
#include "sqliteInt.h"
#include <stdlib.h>
@@ -410,7 +410,7 @@ int sqlite3RunParser(Parse *pParse, const char *zSql, char **pzErrMsg){
db->u1.isInterrupted = 0;
}
pParse->rc = SQLITE_OK;
- pParse->zTail = pParse->zSql = zSql;
+ pParse->zTail = zSql;
i = 0;
assert( pzErrMsg!=0 );
pEngine = sqlite3ParserAlloc((void*(*)(size_t))sqlite3Malloc);