aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authordrh <drh@noemail.net>2020-10-01 15:46:21 +0000
committerdrh <drh@noemail.net>2020-10-01 15:46:21 +0000
commitdeaa61072dd09c153c311b7fb33b94e864b76407 (patch)
treee017aca9a1401fae0b24b9aaaf82078016d74525 /src
parent644f43c0f77f0048d776779848457b3317f6077b (diff)
downloadsqlite-deaa61072dd09c153c311b7fb33b94e864b76407.tar.gz
sqlite-deaa61072dd09c153c311b7fb33b94e864b76407.zip
Fix the OP_SeekScan opcode so that its variable names do not cause problems
for the test/vdbe-compress.tcl script. FossilOrigin-Name: 7a78274a072324b94d6f79e5b7a198b2fa9321ff5d6a528b51f57d3ee95c765b
Diffstat (limited to 'src')
-rw-r--r--src/vdbe.c14
1 files changed, 7 insertions, 7 deletions
diff --git a/src/vdbe.c b/src/vdbe.c
index 2c924abfe..2da839485 100644
--- a/src/vdbe.c
+++ b/src/vdbe.c
@@ -4433,7 +4433,7 @@ seek_not_found:
case OP_SeekScan: {
VdbeCursor *pC;
int res;
- int n;
+ int nStep;
UnpackedRecord r;
assert( pOp[1].opcode==OP_SeekGE );
@@ -4455,8 +4455,8 @@ case OP_SeekScan: {
#endif
break;
}
- n = pOp->p1;
- assert( n>=1 );
+ nStep = pOp->p1;
+ assert( nStep>=1 );
r.pKeyInfo = pC->pKeyInfo;
r.nField = (u16)pOp[1].p4.i;
r.default_rc = 0;
@@ -4478,7 +4478,7 @@ case OP_SeekScan: {
seekscan_search_fail:
#ifdef SQLITE_DEBUG
if( db->flags&SQLITE_VdbeTrace ){
- printf("... %d steps and then skip\n", pOp->p1 - n);
+ printf("... %d steps and then skip\n", pOp->p1 - nStep);
}
#endif
VdbeBranchTaken(1,3);
@@ -4488,14 +4488,14 @@ case OP_SeekScan: {
if( res==0 ){
#ifdef SQLITE_DEBUG
if( db->flags&SQLITE_VdbeTrace ){
- printf("... %d steps and then success\n", pOp->p1 - n);
+ printf("... %d steps and then success\n", pOp->p1 - nStep);
}
#endif
VdbeBranchTaken(2,3);
pOp += 2;
break;
}
- if( n<=0 ){
+ if( nStep<=0 ){
#ifdef SQLITE_DEBUG
if( db->flags&SQLITE_VdbeTrace ){
printf("... fall through after %d steps\n", pOp->p1);
@@ -4504,7 +4504,7 @@ case OP_SeekScan: {
VdbeBranchTaken(0,3);
break;
}
- n--;
+ nStep--;
rc = sqlite3BtreeNext(pC->uc.pCursor, 0);
if( rc ){
if( rc==SQLITE_DONE ){