mirror of
https://github.com/sqlite/sqlite.git
synced 2025-08-07 02:42:48 +03:00
If blocking locks are enabled, avoid using the busy handler when blocked by another process running recovery.
FossilOrigin-Name: a35236757ab57c4c9b34e47c5dbc10d8f1220f8152955f5303cf9c3902ee169b
This commit is contained in:
@@ -3697,11 +3697,10 @@ static SQLITE_NOINLINE int btreeBeginTrans(
|
||||
(void)sqlite3PagerWalWriteLock(pPager, 0);
|
||||
unlockBtreeIfUnused(pBt);
|
||||
}
|
||||
#if defined(SQLITE_ENABLE_SETLK_TIMEOUT) && defined(SQLITE_ENABLE_SNAPSHOT)
|
||||
#if defined(SQLITE_ENABLE_SETLK_TIMEOUT)
|
||||
if( rc==SQLITE_BUSY_TIMEOUT ){
|
||||
/* If a blocking lock timed out, break out of the loop here so that
|
||||
** the busy-handler is not invoked. This can only happen when opening
|
||||
** a transaction on a snapshot. */
|
||||
** the busy-handler is not invoked. */
|
||||
break;
|
||||
}
|
||||
#endif
|
||||
|
Reference in New Issue
Block a user