mirror of
https://github.com/sqlite/sqlite.git
synced 2025-07-30 19:03:16 +03:00
In the fuzzcheck test program, make sure the isspace() and related routines
are not given values outside the range of -1 to 255. FossilOrigin-Name: f298328771d5aaba798d05f50c77ac239c7c72422ff35953463d6876a9659f74
This commit is contained in:
@ -533,7 +533,7 @@ static int decodeDatabase(
|
||||
}
|
||||
memset(a, 0, nAlloc);
|
||||
for(i=k=0; i<n; i++){
|
||||
char c = zIn[i];
|
||||
unsigned char c = (unsigned char)zIn[i];
|
||||
if( isxdigit(c) ){
|
||||
k++;
|
||||
if( k & 1 ){
|
||||
@ -651,7 +651,7 @@ static int block_troublesome_sql(
|
||||
static int runDbSql(sqlite3 *db, const char *zSql){
|
||||
int rc;
|
||||
sqlite3_stmt *pStmt;
|
||||
while( isspace(zSql[0]) ) zSql++;
|
||||
while( isspace(zSql[0]&0x7f) ) zSql++;
|
||||
if( zSql[0]==0 ) return SQLITE_OK;
|
||||
if( eVerbosity>=4 ){
|
||||
printf("RUNNING-SQL: [%s]\n", zSql);
|
||||
|
Reference in New Issue
Block a user