mirror of
https://github.com/sqlite/sqlite.git
synced 2025-08-08 14:02:16 +03:00
In synchronous=normal mode, do not sync the log after every transaction. In synchronous=full mode, sync the log and add any extra frames required to avoid blast-radius related problems after each transaction.
FossilOrigin-Name: 9bc9b6847303d0324543a9ded8dd0473490122d8
This commit is contained in:
@@ -3764,6 +3764,7 @@ static int pagerOpenLog(Pager *pPager){
|
||||
sqlite3OsFileControl(pPager->fd, SQLITE_FCNTL_LOCKSTATE, &locktype);
|
||||
assert( locktype==SQLITE_LOCK_SHARED );
|
||||
#endif
|
||||
pPager->state = PAGER_SHARED;
|
||||
}
|
||||
|
||||
return SQLITE_OK;
|
||||
@@ -4880,7 +4881,7 @@ int sqlite3PagerCommitPhaseOne(
|
||||
PgHdr *pList = sqlite3PcacheDirtyList(pPager->pPCache);
|
||||
if( pList ){
|
||||
rc = sqlite3LogFrames(pPager->pLog, pPager->pageSize, pList,
|
||||
pPager->dbSize, 1, 1
|
||||
pPager->dbSize, 1, pPager->fullSync
|
||||
);
|
||||
}
|
||||
sqlite3PcacheCleanAll(pPager->pPCache);
|
||||
|
Reference in New Issue
Block a user