1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-11 01:42:22 +03:00

Always use "(char*)0" to terminate the argument list of sqliteSetString().

This is needed for 64-bit systems that use a 32-bit integer by default. (CVS 1126)

FossilOrigin-Name: 656c90387a4a714b4f31040ece9b0e15e30934af
This commit is contained in:
drh
2003-12-06 21:43:55 +00:00
parent 3a6629d27e
commit 41743984bf
15 changed files with 106 additions and 101 deletions

View File

@@ -15,7 +15,7 @@
** individual tokens and sends those tokens one-by-one over to the
** parser for analysis.
**
** $Id: tokenize.c,v 1.64 2003/09/27 13:39:39 drh Exp $
** $Id: tokenize.c,v 1.65 2003/12/06 21:43:56 drh Exp $
*/
#include "sqliteInt.h"
#include "os.h"
@@ -413,7 +413,7 @@ int sqliteRunParser(Parse *pParse, const char *zSql, char **pzErrMsg){
i = 0;
pEngine = sqliteParserAlloc((void*(*)(int))malloc);
if( pEngine==0 ){
sqliteSetString(pzErrMsg, "out of memory", 0);
sqliteSetString(pzErrMsg, "out of memory", (char*)0);
return 1;
}
pParse->sLastToken.dyn = 0;
@@ -429,7 +429,7 @@ int sqliteRunParser(Parse *pParse, const char *zSql, char **pzErrMsg){
case TK_COMMENT: {
if( (db->flags & SQLITE_Interrupt)!=0 ){
pParse->rc = SQLITE_INTERRUPT;
sqliteSetString(pzErrMsg, "interrupt", 0);
sqliteSetString(pzErrMsg, "interrupt", (char*)0);
goto abort_parse;
}
break;
@@ -464,7 +464,8 @@ abort_parse:
}
sqliteParserFree(pEngine, free);
if( pParse->rc!=SQLITE_OK && pParse->rc!=SQLITE_DONE && pParse->zErrMsg==0 ){
sqliteSetString(&pParse->zErrMsg, sqlite_error_string(pParse->rc), 0);
sqliteSetString(&pParse->zErrMsg, sqlite_error_string(pParse->rc),
(char*)0);
}
if( pParse->zErrMsg ){
if( pzErrMsg && *pzErrMsg==0 ){