diff options
author | mistachkin <mistachkin@noemail.net> | 2015-12-16 22:06:52 +0000 |
---|---|---|
committer | mistachkin <mistachkin@noemail.net> | 2015-12-16 22:06:52 +0000 |
commit | 8ccdef6be492dd2b1561ec4305ad5e749ada30e3 (patch) | |
tree | 4ad825bf9494eb45261030b4276491ac476e97b9 /src/test8.c | |
parent | 8c7cd6a9d89c8473273f07edc404ff5425d3e2a4 (diff) | |
download | sqlite-8ccdef6be492dd2b1561ec4305ad5e749ada30e3.tar.gz sqlite-8ccdef6be492dd2b1561ec4305ad5e749ada30e3.zip |
Fix some more harmless compiler warnings.
FossilOrigin-Name: 18f531e1cf3c8bb986d912c9c5e3f5698360c93e
Diffstat (limited to 'src/test8.c')
-rw-r--r-- | src/test8.c | 10 |
1 files changed, 5 insertions, 5 deletions
diff --git a/src/test8.c b/src/test8.c index 3e506e36b..fb781ac8f 100644 --- a/src/test8.c +++ b/src/test8.c @@ -863,7 +863,7 @@ static int echoBestIndex(sqlite3_vtab *tab, sqlite3_index_info *pIdxInfo){ iCol = pConstraint->iColumn; if( iCol<0 || pVtab->aIndex[iCol] ){ - char *zCol = iCol>=0 ? pVtab->aCol[iCol] : "rowid"; + char *zNewCol = iCol>=0 ? pVtab->aCol[iCol] : "rowid"; char *zOp = 0; useIdx = 1; switch( pConstraint->op ){ @@ -895,9 +895,9 @@ static int echoBestIndex(sqlite3_vtab *tab, sqlite3_index_info *pIdxInfo){ } if( zOp[0]=='L' ){ zNew = sqlite3_mprintf(" %s %s LIKE (SELECT '%%'||?||'%%')", - zSep, zCol); + zSep, zNewCol); } else { - zNew = sqlite3_mprintf(" %s %s %s ?", zSep, zCol, zOp); + zNew = sqlite3_mprintf(" %s %s %s ?", zSep, zNewCol, zOp); } string_concat(&zQuery, zNew, 1, &rc); @@ -915,9 +915,9 @@ static int echoBestIndex(sqlite3_vtab *tab, sqlite3_index_info *pIdxInfo){ pIdxInfo->aOrderBy->iColumn<0 || pVtab->aIndex[pIdxInfo->aOrderBy->iColumn]) ){ int iCol = pIdxInfo->aOrderBy->iColumn; - char *zCol = iCol>=0 ? pVtab->aCol[iCol] : "rowid"; + char *zNewCol = iCol>=0 ? pVtab->aCol[iCol] : "rowid"; char *zDir = pIdxInfo->aOrderBy->desc?"DESC":"ASC"; - zNew = sqlite3_mprintf(" ORDER BY %s %s", zCol, zDir); + zNew = sqlite3_mprintf(" ORDER BY %s %s", zNewCol, zDir); string_concat(&zQuery, zNew, 1, &rc); pIdxInfo->orderByConsumed = 1; } |