/ Check-in [45abd5c0]
Login

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

Overview
Comment:Fix a variable-declaration after code problem in btree.c. Harmless in GCC and CLANG but unacceptable for MSVC.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: 45abd5c0bad2847861f3b26a7040490aa9bb1332
User & Date: drh 2014-08-23 19:08:09
Context
2014-08-23
19:42
Another memory allocator performance optimization. check-in: 6da6f46d user: drh tags: trunk
19:08
Fix a variable-declaration after code problem in btree.c. Harmless in GCC and CLANG but unacceptable for MSVC. check-in: 45abd5c0 user: drh tags: trunk
19:04
Changes to sqlite3ScratchMalloc() that make the entire memory allocation interface a little faster and about 100 bytes smaller. check-in: f83daa16 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/btree.c.

   641    641   ** table, for example in BtreeDelete() or BtreeInsert().
   642    642   **
   643    643   ** Implementation note:  This routine merely checks to see if any cursors
   644    644   ** need to be saved.  It calls out to saveCursorsOnList() in the (unusual)
   645    645   ** event that cursors are in need to being saved.
   646    646   */
   647    647   static int saveAllCursors(BtShared *pBt, Pgno iRoot, BtCursor *pExcept){
   648         -  assert( sqlite3_mutex_held(pBt->mutex) );
   649         -  assert( pExcept==0 || pExcept->pBt==pBt );
   650    648     BtCursor *p;
          649  +  assert( sqlite3_mutex_held(pBt->mutex) );
          650  +  assert( pExcept==0 || pExcept->pBt==pBt );
   651    651     for(p=pBt->pCursor; p; p=p->pNext){
   652    652       if( p!=pExcept && (0==iRoot || p->pgnoRoot==iRoot) ) break;
   653    653     }
   654    654     return p ? saveCursorsOnList(p, iRoot, pExcept) : SQLITE_OK;
   655    655   }
   656    656   
   657    657   /* This helper routine to saveAllCursors does the actual work of saving