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

Improvement to a comment. No changes to code.

FossilOrigin-Name: 486949fc03706e0056439b52ce60931ea4ce0a65e391da7f6287fe13862de251
This commit is contained in:
drh
2017-11-14 03:42:52 +00:00
parent 2e9b0923ac
commit 8b17ac1919
3 changed files with 10 additions and 7 deletions

View File

@@ -2178,6 +2178,9 @@ static int walIndexReadHdr(Wal *pWal, int *pChanged){
walIndexClose(pWal, 0);
pWal->bShmUnreliable = 0;
assert( pWal->nWiData>0 && pWal->apWiData[0]==0 );
/* walIndexRecover() might have returned SHORT_READ if a concurrent
** writer truncated the WAL out from under it. If that happens, it
** indicates that a writer has fixed the SHM file for us, so retry */
if( rc==SQLITE_IOERR_SHORT_READ ) rc = WAL_RETRY;
}
pWal->exclusiveMode = WAL_NORMAL_MODE;