1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-07 02:42:48 +03:00

Add an sqlite3FaultSim() all to make it easier to simulate IO errors in

a VACUUM commit.

FossilOrigin-Name: 8bfde416c51f4e087275aebf652a73985515e810
This commit is contained in:
drh
2016-04-25 22:39:42 +00:00
parent 6c96358601
commit ead01fd272
3 changed files with 10 additions and 7 deletions

View File

@@ -6210,6 +6210,9 @@ int sqlite3PagerCommitPhaseOne(
/* If a prior error occurred, report that error again. */
if( NEVER(pPager->errCode) ) return pPager->errCode;
/* Provide the ability to easily simulate an I/O error during testing */
if( (rc = sqlite3FaultSim(400))!=SQLITE_OK ) return rc;
PAGERTRACE(("DATABASE SYNC: File=%s zMaster=%s nSize=%d\n",
pPager->zFilename, zMaster, pPager->dbSize));