1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-05 15:55:57 +03:00

When a lock fails due to an I/O error (not an SQLITE_BUSY) then the checkpoint

should fail.

FossilOrigin-Name: c6eb0a27270df69018576232d8f97c16d63d8f6e
This commit is contained in:
drh
2010-06-02 20:38:20 +00:00
parent 6e6bd5658f
commit 2d37e1cfb9
3 changed files with 23 additions and 10 deletions

View File

@@ -1438,8 +1438,11 @@ static int walCheckpoint(
){
pInfo->aReadMark[i] = 0;
walUnlockExclusive(pWal, WAL_READ_LOCK(i), 1);
}else{
}else if( rc==SQLITE_BUSY ){
mxSafeFrame = y-1;
}else{
walIteratorFree(pIter);
return rc;
}
}
}
@@ -1478,7 +1481,7 @@ static int walCheckpoint(
/* Release the reader lock held while backfilling */
walUnlockExclusive(pWal, WAL_READ_LOCK(0), 1);
}else{
}else if( rc==SQLITE_BUSY ){
/* Reset the return code so as not to report a checkpoint failure
** just because active readers prevent any backfill.
*/