aboutsummaryrefslogtreecommitdiff
path: root/src/func.c
diff options
context:
space:
mode:
authordanielk1977 <danielk1977@noemail.net>2009-02-19 14:39:25 +0000
committerdanielk1977 <danielk1977@noemail.net>2009-02-19 14:39:25 +0000
commit6ab3a2ec8a7a21f8eb607679875e3193e6d16f4c (patch)
tree58e9ac88aa2cd60f02228baeda46b9c16eb6d5a9 /src/func.c
parent076d4661a68f67dbabc421eab124fe5908ebbeee (diff)
downloadsqlite-6ab3a2ec8a7a21f8eb607679875e3193e6d16f4c.tar.gz
sqlite-6ab3a2ec8a7a21f8eb607679875e3193e6d16f4c.zip
Changes to reduce the heap space consumed by triggers, views and tables in the in-memory representation of the schema. Also to reduce the space used by prepared statements slightly. (CVS 6305)
FossilOrigin-Name: d9f6ffbc5ea090ba0daac571fc9a6c68b9c864e4
Diffstat (limited to 'src/func.c')
-rw-r--r--src/func.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/src/func.c b/src/func.c
index 07671ff6b..3deffc003 100644
--- a/src/func.c
+++ b/src/func.c
@@ -16,7 +16,7 @@
** sqliteRegisterBuildinFunctions() found at the bottom of the file.
** All other code has file scope.
**
-** $Id: func.c,v 1.222 2009/02/04 03:59:25 shane Exp $
+** $Id: func.c,v 1.223 2009/02/19 14:39:25 danielk1977 Exp $
*/
#include "sqliteInt.h"
#include <stdlib.h>
@@ -1323,12 +1323,13 @@ void sqlite3RegisterLikeFunctions(sqlite3 *db, int caseSensitive){
*/
int sqlite3IsLikeFunction(sqlite3 *db, Expr *pExpr, int *pIsNocase, char *aWc){
FuncDef *pDef;
- if( pExpr->op!=TK_FUNCTION || !pExpr->pList ){
- return 0;
- }
- if( pExpr->pList->nExpr!=2 ){
+ if( pExpr->op!=TK_FUNCTION
+ || !pExpr->x.pList
+ || pExpr->x.pList->nExpr!=2
+ ){
return 0;
}
+ assert( !ExprHasProperty(pExpr, EP_xIsSelect) );
pDef = sqlite3FindFunction(db, (char*)pExpr->token.z, pExpr->token.n, 2,
SQLITE_UTF8, 0);
if( pDef==0 || (pDef->flags & SQLITE_FUNC_LIKE)==0 ){