/ Check-in [83bc37af]
Login

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

Overview
Comment:Make use of xFetch, if it is available when doing a VACUUM or a backup.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | experimental-mmap
Files: files | file ages | folders
SHA1: 83bc37af07857960c11275891f853a358dcbbf05
User & Date: drh 2013-04-03 03:53:15
Context
2013-04-03
10:50
Initialize the mmap_limit of temporary files to the configured mmap_limit. check-in: 24bab759 user: drh tags: experimental-mmap
03:53
Make use of xFetch, if it is available when doing a VACUUM or a backup. check-in: 83bc37af user: drh tags: experimental-mmap
01:26
Add the -mmap option to the command-line shell, for setting the default mmap_limit. check-in: fc30d06c user: drh tags: experimental-mmap
Changes
Hide Diffs Unified Diffs Show Whitespace Changes Patch

Changes to src/backup.c.

393
394
395
396
397
398
399
400

401
402
403
404
405
406
407
    */
    nSrcPage = (int)sqlite3BtreeLastPage(p->pSrc);
    assert( nSrcPage>=0 );
    for(ii=0; (nPage<0 || ii<nPage) && p->iNext<=(Pgno)nSrcPage && !rc; ii++){
      const Pgno iSrcPg = p->iNext;                 /* Source page number */
      if( iSrcPg!=PENDING_BYTE_PAGE(p->pSrc->pBt) ){
        DbPage *pSrcPg;                             /* Source page object */
        rc = sqlite3PagerGet(pSrcPager, iSrcPg, &pSrcPg);

        if( rc==SQLITE_OK ){
          rc = backupOnePage(p, iSrcPg, sqlite3PagerGetData(pSrcPg), 0);
          sqlite3PagerUnref(pSrcPg);
        }
      }
      p->iNext++;
    }







|
>







393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
    */
    nSrcPage = (int)sqlite3BtreeLastPage(p->pSrc);
    assert( nSrcPage>=0 );
    for(ii=0; (nPage<0 || ii<nPage) && p->iNext<=(Pgno)nSrcPage && !rc; ii++){
      const Pgno iSrcPg = p->iNext;                 /* Source page number */
      if( iSrcPg!=PENDING_BYTE_PAGE(p->pSrc->pBt) ){
        DbPage *pSrcPg;                             /* Source page object */
        rc = sqlite3PagerAcquire(pSrcPager, iSrcPg, &pSrcPg,
                                 PAGER_ACQUIRE_READONLY);
        if( rc==SQLITE_OK ){
          rc = backupOnePage(p, iSrcPg, sqlite3PagerGetData(pSrcPg), 0);
          sqlite3PagerUnref(pSrcPg);
        }
      }
      p->iNext++;
    }