1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-08-07 02:42:48 +03:00

Ensure the required b-tree mutexes are held for "CREATE TABLE IF NOT EXISTS" and "DROP TABLE IF EXISTS" statements on attached databases.

FossilOrigin-Name: 67bde01614edd944b769ab28488bac1dbbf17d88beee62ca7f1e45681aa3d402
This commit is contained in:
dan
2021-05-20 11:42:51 +00:00
parent cd1499f47b
commit a8f249f1e7
4 changed files with 11 additions and 9 deletions

View File

@@ -7247,6 +7247,7 @@ case OP_JournalMode: { /* out2 */
pPager = sqlite3BtreePager(pBt);
eOld = sqlite3PagerGetJournalMode(pPager);
if( eNew==PAGER_JOURNALMODE_QUERY ) eNew = eOld;
assert( sqlite3BtreeHoldsMutex(pBt) );
if( !sqlite3PagerOkToChangeJournalMode(pPager) ) eNew = eOld;
#ifndef SQLITE_OMIT_WAL