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

Fix a crash that can occur with a skip-scan on an index with

expressions when SQLITE_ENABLE_EXPLAIN_COMMENTS is defined.

FossilOrigin-Name: 25f34cb9b576a2d4250a06a7dbf88010b1c11675
This commit is contained in:
drh
2015-09-18 18:09:28 +00:00
parent e5c61f81c3
commit e63e8a6c78
4 changed files with 27 additions and 10 deletions

View File

@@ -514,8 +514,8 @@ static int codeAllEqualityTerms(
sqlite3VdbeJumpHere(v, j);
for(j=0; j<nSkip; j++){
sqlite3VdbeAddOp3(v, OP_Column, iIdxCur, j, regBase+j);
assert( pIdx->aiColumn[j]>=0 );
VdbeComment((v, "%s", pIdx->pTable->aCol[pIdx->aiColumn[j]].zName));
testcase( pIdx->aiColumn[j]==(-2) );
VdbeComment((v, "%s", explainIndexColumnName(pIdx, j)));
}
}