mirror of
https://github.com/sqlite/sqlite.git
synced 2025-08-04 04:42:17 +03:00
Add a missing walIndexUnmap() call to the checkpoint code. Change a couple of SQLITE_CANTOPEN constants to SQLITE_CANTOPEN_BKPT.
FossilOrigin-Name: 1f9e8c5c27ae2c68bc01d8e2bb2c662be7b3f161
This commit is contained in:
@@ -567,7 +567,7 @@ int sqlite3WalOpen(
|
||||
int nWal; /* Length of zWal in bytes */
|
||||
|
||||
assert( zDb );
|
||||
if( pVfs->xShmOpen==0 ) return SQLITE_CANTOPEN;
|
||||
if( pVfs->xShmOpen==0 ) return SQLITE_CANTOPEN_BKPT;
|
||||
|
||||
/* Allocate an instance of struct Wal to return. */
|
||||
*ppWal = 0;
|
||||
@@ -1237,6 +1237,7 @@ int sqlite3WalCheckpoint(
|
||||
}
|
||||
|
||||
/* Release the locks. */
|
||||
walIndexUnmap(pWal);
|
||||
walSetLock(pWal, SQLITE_SHM_UNLOCK);
|
||||
return rc;
|
||||
}
|
||||
|
Reference in New Issue
Block a user