/ Check-in [afb2484c]
Login

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

Overview
Comment:Simplification of changes for SQLITE_OMIT_WAL support in pager.c.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: afb2484c64bf0cdec8240b9ecd0a794c44a63066
User & Date: shaneh 2010-08-26 05:23:37
Context
2010-08-26
07:59
Improve coverage of rtree.c some more. check-in: bee1959d user: dan tags: trunk
05:23
Simplification of changes for SQLITE_OMIT_WAL support in pager.c. check-in: afb2484c user: shaneh tags: trunk
2010-08-25
20:35
Reinstate the "sqlite" alias for backwards compatibility (but leave it undocumented) but remove the PackageProvide for "sqlite". check-in: 699cc6b4 user: drh tags: trunk
Changes
Hide Diffs Side-by-Side Diffs Ignore Whitespace Patch

Changes to src/pager.c.

  2995   2995     ** function returns zero if the WAL is not open (i.e. Pager.pWal==0), or
  2996   2996     ** if the database size is not available. The database size is not
  2997   2997     ** available from the WAL sub-system if the log file is empty or
  2998   2998     ** contains no valid committed transactions.
  2999   2999     */
  3000   3000     assert( pPager->eState==PAGER_OPEN );
  3001   3001     assert( pPager->eLock>=SHARED_LOCK || pPager->noReadlock );
  3002         -#ifndef SQLITE_OMIT_WAL
  3003   3002     nPage = sqlite3WalDbsize(pPager->pWal);
  3004         -#else
  3005         -  nPage = 0;
  3006         -#endif
  3007   3003   
  3008   3004     /* If the database size was not available from the WAL sub-system,
  3009   3005     ** determine it based on the size of the database file. If the size
  3010   3006     ** of the database file is not an integer multiple of the page-size,
  3011   3007     ** round down to the nearest page. Except, any file larger than 0
  3012   3008     ** bytes in size is considered to contain at least one page.
  3013   3009     */