/ 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 Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/backup.c.

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