/ Check-in [a7e0e7a4]
Login

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

Overview
Comment:Adjust the bitvec related sqlite3_log messages added by [9527089b].
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | begin-concurrent
Files: files | file ages | folders
SHA3-256: a7e0e7a4835314a04e065839a7f88b074eda795da2b2da5741b2afc096421a32
User & Date: dan 2017-05-26 18:18:51
Wiki:begin-concurrent
Context
2017-05-29
14:27
Enhance the log messages emitted when a page conflict is detected. check-in: 92618492 user: dan tags: begin-concurrent
2017-05-26
18:18
Adjust the bitvec related sqlite3_log messages added by [9527089b]. check-in: a7e0e7a4 user: dan tags: begin-concurrent
16:51
Add extra test cases for deferred page allocation. check-in: 9df01957 user: dan tags: begin-concurrent
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/bitvec.c.

   167    167   ** Otherwise the behavior is undefined.
   168    168   */
   169    169   int sqlite3BitvecSet(Bitvec *p, u32 i){
   170    170     u32 h;
   171    171     if( p==0 ) return SQLITE_OK;
   172    172     assert( i>0 );
   173    173     assert( i<=p->iSize );
   174         -  if( i>p->iSize ){
          174  +  if( i>p->iSize || i==0 ){
   175    175       sqlite3_log(SQLITE_ERROR, 
   176    176           "Bitvec: setting bit %d of bitvec size %d\n", (int)i, (int)p->iSize
   177    177       );
   178    178     }
   179    179     i--;
   180    180     while((p->iSize > BITVEC_NBIT) && p->iDivisor) {
   181    181       u32 bin = i/p->iDivisor;

Changes to src/pager.c.

  5382   5382     if( rc!=SQLITE_OK ){
  5383   5383       assert( !MEMDB );
  5384   5384       pager_unlock(pPager);
  5385   5385       assert( pPager->eState==PAGER_OPEN );
  5386   5386     }else{
  5387   5387       pPager->eState = PAGER_READER;
  5388   5388       pPager->hasHeldSharedLock = 1;
  5389         -#ifndef SQLITE_OMIT_CONCURRENT
  5390         -    if( pPager->pAllRead ){
  5391         -      sqlite3_log(SQLITE_ERROR, 
  5392         -          "Bitvec: pAllRead already allocated in PagerSharedLock()"
  5393         -      );
  5394         -    }
  5395         -#endif
  5396   5389     }
  5397   5390     return rc;
  5398   5391   }
  5399   5392   
  5400   5393   /*
  5401   5394   ** If the reference count has reached zero, rollback any active
  5402   5395   ** transaction and unlock the pager.
................................................................................
  5887   5880         ** WAL mode sets Pager.eState to PAGER_WRITER_LOCKED or CACHEMOD
  5888   5881         ** when it has an open transaction, but never to DBMOD or FINISHED.
  5889   5882         ** This is because in those states the code to roll back savepoint 
  5890   5883         ** transactions may copy data from the sub-journal into the database 
  5891   5884         ** file as well as into the page cache. Which would be incorrect in 
  5892   5885         ** WAL mode.
  5893   5886         */
  5894         -#ifndef SQLITE_OMIT_CONCURRENT
  5895         -      if( pPager->pAllRead 
  5896         -       && pPager->dbSize!=sqlite3BitvecSize(pPager->pAllRead) 
  5897         -      ){
  5898         -        sqlite3_log(SQLITE_ERROR, 
  5899         -            "Bitvec: pAllRead size is %d, dbOrigSize set to %d", 
  5900         -            (int)sqlite3BitvecSize(pPager->pAllRead), pPager->dbSize
  5901         -        );
  5902         -      }
  5903         -#endif
  5904   5887         pPager->eState = PAGER_WRITER_LOCKED;
  5905   5888         pPager->dbHintSize = pPager->dbSize;
  5906   5889         pPager->dbFileSize = pPager->dbSize;
  5907   5890         pPager->dbOrigSize = pPager->dbSize;
  5908   5891         pPager->journalOff = 0;
  5909   5892       }
  5910   5893