/ Check-in [2f2ecb99]
Login

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Avoid calling sqlite3BtreeKeysize() on a b-tree cursor in SKIPNEXT or SKIPPREV state. Cherrypick of [54e7d3fcb1].
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | branch-3.8.7
Files: files | file ages | folders
SHA1: 2f2ecb994889acb783616acb7307f8fed962d213
User & Date: dan 2014-11-17 19:44:44
Original Comment: Avoid calling sqlite3BtreeKeysize() on a b-tree cursor in SKIPNEXT or SKIPPREV state.
Context
2014-11-17
20:33
Remove code from sqlite3BtreeKeySize() made unreachable by the previous check-in. check-in: 57c4aa98 user: drh tags: branch-3.8.7
19:44
Avoid calling sqlite3BtreeKeysize() on a b-tree cursor in SKIPNEXT or SKIPPREV state. Cherrypick of [54e7d3fcb1]. check-in: 2f2ecb99 user: dan tags: branch-3.8.7
19:42
Avoid calling sqlite3BtreeKeysize() on a b-tree cursor in SKIPNEXT or SKIPPREV state. check-in: 54e7d3fc user: dan tags: trunk
19:25
Improved comments on the BtCursor.skipNext field. No changes to code. check-in: e956e7db user: drh tags: branch-3.8.7
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/vdbe.c.

  4401   4401       rc = pModule->xRowid(pC->pVtabCursor, &v);
  4402   4402       sqlite3VtabImportErrmsg(p, pVtab);
  4403   4403   #endif /* SQLITE_OMIT_VIRTUALTABLE */
  4404   4404     }else{
  4405   4405       assert( pC->pCursor!=0 );
  4406   4406       rc = sqlite3VdbeCursorRestore(pC);
  4407   4407       if( rc ) goto abort_due_to_error;
         4408  +    if( pC->nullRow ){
         4409  +      pOut->flags = MEM_Null;
         4410  +      break;
         4411  +    }
  4408   4412       rc = sqlite3BtreeKeySize(pC->pCursor, &v);
  4409   4413       assert( rc==SQLITE_OK );  /* Always so because of CursorRestore() above */
  4410   4414     }
  4411   4415     pOut->u.i = v;
  4412   4416     break;
  4413   4417   }
  4414   4418