/ Check-in [68360cd2]
Login
SQLite training in Houston TX on 2019-11-05 (details)
Part of the 2019 Tcl Conference

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

Overview
Comment:Fix an assert() that might be false for a corrupt database.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 68360cd2211b7ab25dd4ca55a2e82e31f51f2976
User & Date: drh 2016-01-01 03:37:44
Context
2016-01-01
16:26
Avoid misaligned memory allocations on Sparc in sqlite3VdbeMakeReady(). This fixes a problem introduced by check-in [a9e819082b]. check-in: a304e346 user: drh tags: trunk
14:14
Merge recent trunk enhancements. check-in: 6bea792c user: drh tags: begin-concurrent
13:31
Merge all recent trunk enhancements. check-in: 5b700f31 user: drh tags: apple-osx
13:25
Merge the latest enhancements from trunk. check-in: c0be246a user: drh tags: sessions
03:37
Fix an assert() that might be false for a corrupt database. check-in: 68360cd2 user: drh tags: trunk
00:15
Remove unreachable branches from the new JSON aggregate functions. check-in: 6e30f8c6 user: drh tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/btree.c.

8217
8218
8219
8220
8221
8222
8223
8224
8225
8226
8227
8228
8229
8230
8231
      releasePage(pCur->apPage[pCur->iPage--]);
    }
    rc = balance(pCur);
  }

  if( rc==SQLITE_OK ){
    if( bSkipnext ){
      assert( bPreserve && pCur->iPage==iCellDepth );
      assert( pPage==pCur->apPage[pCur->iPage] );
      assert( (pPage->nCell>0 || CORRUPT_DB) && iCellIdx<=pPage->nCell );
      pCur->eState = CURSOR_SKIPNEXT;
      if( iCellIdx>=pPage->nCell ){
        pCur->skipNext = -1;
        pCur->aiIdx[iCellDepth] = pPage->nCell-1;
      }else{







|







8217
8218
8219
8220
8221
8222
8223
8224
8225
8226
8227
8228
8229
8230
8231
      releasePage(pCur->apPage[pCur->iPage--]);
    }
    rc = balance(pCur);
  }

  if( rc==SQLITE_OK ){
    if( bSkipnext ){
      assert( bPreserve && (pCur->iPage==iCellDepth || CORRUPT_DB) );
      assert( pPage==pCur->apPage[pCur->iPage] );
      assert( (pPage->nCell>0 || CORRUPT_DB) && iCellIdx<=pPage->nCell );
      pCur->eState = CURSOR_SKIPNEXT;
      if( iCellIdx>=pPage->nCell ){
        pCur->skipNext = -1;
        pCur->aiIdx[iCellDepth] = pPage->nCell-1;
      }else{