1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-27 20:41:58 +03:00

In the sqlite_stmt extension, store the result of strlen() in a 64-bit

integer to avoid a compiler warning, even though we know that the length
will always fit comfortably in 32 bits.

FossilOrigin-Name: 3fe19452499afc8e6b38905e1ce7e9153adbfebf10dccf39da4b7f1b0cd24f05
This commit is contained in:
drh
2022-07-11 19:12:47 +00:00
parent f1ab642cde
commit d5c2e08449
3 changed files with 8 additions and 8 deletions

View File

@ -220,7 +220,7 @@ static int stmtFilter(
ppRow = &pCur->pRow;
for(p=sqlite3_next_stmt(pCur->db, 0); p; p=sqlite3_next_stmt(pCur->db, p)){
const char *zSql = sqlite3_sql(p);
int nSql = zSql ? strlen(zSql)+1 : 0;
sqlite3_int64 nSql = zSql ? strlen(zSql)+1 : 0;
StmtRow *pNew = (StmtRow*)sqlite3_malloc(sizeof(StmtRow) + nSql);
if( pNew==0 ) return SQLITE_NOMEM;