Many hyperlinks are disabled.
Use anonymous login
to enable hyperlinks.
Overview
Comment: | Discard the pager-cache when the page-size is changed. (CVS 3719) |
---|---|
Downloads: | Tarball | ZIP archive |
Timelines: | family | ancestors | descendants | both | trunk |
Files: | files | file ages | folders |
SHA1: |
e4209f7193d160709b0d8b5cd358df56 |
User & Date: | danielk1977 2007-03-26 15:46:01.000 |
Context
2007-03-26
| ||
16:13 | Run some malloc() tests with exclusive-access mode. (CVS 3720) (check-in: 9ebba46902 user: danielk1977 tags: trunk) | |
15:46 | Discard the pager-cache when the page-size is changed. (CVS 3719) (check-in: e4209f7193 user: danielk1977 tags: trunk) | |
13:48 | Avoid unnecessary calls to pager_unwritelock() when in exclusive-access mode. Add the speed2.test script to the test suite. (CVS 3718) (check-in: ab53f50863 user: drh tags: trunk) | |
Changes
Changes to src/pager.c.
︙ | ︙ | |||
14 15 16 17 18 19 20 | ** The pager is used to access a database disk file. It implements ** atomic commit and rollback through the use of a journal file that ** is separate from the database file. The pager also implements file ** locking to prevent two processes from writing the same database ** file simultaneously, or one process from reading the database while ** another is writing. ** | | | 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 | ** The pager is used to access a database disk file. It implements ** atomic commit and rollback through the use of a journal file that ** is separate from the database file. The pager also implements file ** locking to prevent two processes from writing the same database ** file simultaneously, or one process from reading the database while ** another is writing. ** ** @(#) $Id: pager.c,v 1.299 2007/03/26 15:46:01 danielk1977 Exp $ */ #ifndef SQLITE_OMIT_DISKIO #include "sqliteInt.h" #include "os.h" #include "pager.h" #include <assert.h> #include <string.h> |
︙ | ︙ | |||
1821 1822 1823 1824 1825 1826 1827 | /* ** Set the page size. Return the new size. If the suggest new page ** size is inappropriate, then an alternative page size is selected ** and returned. */ int sqlite3PagerSetPagesize(Pager *pPager, int pageSize){ assert( pageSize>=512 && pageSize<=SQLITE_MAX_PAGE_SIZE ); | | > | 1821 1822 1823 1824 1825 1826 1827 1828 1829 1830 1831 1832 1833 1834 1835 1836 | /* ** Set the page size. Return the new size. If the suggest new page ** size is inappropriate, then an alternative page size is selected ** and returned. */ int sqlite3PagerSetPagesize(Pager *pPager, int pageSize){ assert( pageSize>=512 && pageSize<=SQLITE_MAX_PAGE_SIZE ); if( !pPager->memDb && pPager->nRef==0 ){ pager_reset(pPager); pPager->pageSize = pageSize; sqlite3ReallocOrFree((void **)&pPager->pTmpSpace, pageSize); } return pPager->pageSize; } /* |
︙ | ︙ |