1
0
mirror of https://github.com/sqlite/sqlite.git synced 2026-01-06 08:01:16 +03:00

Change the journal_mode pragma so that it always returns the current

journal mode, even on a failed attempt to change the journal mode.
Allow the journal mode to be changed as long as there is not a pending
transaction.  Ticket #3811. (CVS 6526)

FossilOrigin-Name: 419e320ae51639794335d19699f8e1189e524e7d
This commit is contained in:
drh
2009-04-20 17:43:03 +00:00
parent e6e7ecb421
commit 8a93919082
7 changed files with 136 additions and 39 deletions

View File

@@ -22,7 +22,7 @@
** COMMIT
** ROLLBACK
**
** $Id: build.c,v 1.528 2009/04/08 13:51:51 drh Exp $
** $Id: build.c,v 1.529 2009/04/20 17:43:03 drh Exp $
*/
#include "sqliteInt.h"
@@ -158,7 +158,9 @@ void sqlite3FinishCoding(Parse *pParse){
if( (mask & pParse->cookieMask)==0 ) continue;
sqlite3VdbeUsesBtree(v, iDb);
sqlite3VdbeAddOp2(v,OP_Transaction, iDb, (mask & pParse->writeMask)!=0);
sqlite3VdbeAddOp2(v,OP_VerifyCookie, iDb, pParse->cookieValue[iDb]);
if( db->init.busy==0 ){
sqlite3VdbeAddOp2(v,OP_VerifyCookie, iDb, pParse->cookieValue[iDb]);
}
}
#ifndef SQLITE_OMIT_VIRTUALTABLE
{