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

Fix a faulty assert() in the WAL-mode logic for read-only shared memory.

FossilOrigin-Name: a13cfe616284f4ee86f0406e7b8fe8f9ba6e6990
This commit is contained in:
drh
2011-06-02 17:24:49 +00:00
parent 070d422d31
commit 5bf3934652
3 changed files with 8 additions and 8 deletions

View File

@@ -2152,7 +2152,7 @@ static int walTryBeginRead(Wal *pWal, int *pChanged, int useWal, int cnt){
}
}
if( mxI==0 ){
assert( rc==SQLITE_BUSY );
assert( rc==SQLITE_BUSY || (pWal->readOnly & WAL_SHM_RDONLY)!=0 );
return rc==SQLITE_BUSY ? WAL_RETRY : SQLITE_READONLY_CANTLOCK;
}