1
1
diff --git a/sqlite3-binding.c b/sqlite3-binding.c
2
- index f077152..98f1857 100644
2
+ index a4e32d1..7c35ee9 100644
3
3
--- a/sqlite3-binding.c
4
4
+++ b/sqlite3-binding.c
5
- @@ -57211 ,6 +57211 ,38 @@ SQLITE_PRIVATE int sqlite3PagerWalFramesize(Pager *pPager){
5
+ @@ -58311 ,6 +58311 ,38 @@ SQLITE_PRIVATE int sqlite3PagerWalFramesize(Pager *pPager){
6
6
7
7
#endif /* SQLITE_OMIT_DISKIO */
8
8
@@ -41,7 +41,7 @@ index f077152..98f1857 100644
41
41
/************** End of pager.c ***********************************************/
42
42
/************** Begin file wal.c *********************************************/
43
43
/*
44
- @@ -103066 ,6 +103098 ,13 @@ static int resolveAttachExpr(NameContext *pName, Expr *pExpr)
44
+ @@ -105977 ,6 +106009 ,13 @@ static int resolveAttachExpr(NameContext *pName, Expr *pExpr)
45
45
return rc;
46
46
}
47
47
@@ -55,7 +55,7 @@ index f077152..98f1857 100644
55
55
/*
56
56
** An SQL user-function registered to do the work of an ATTACH statement. The
57
57
** three arguments to the function come directly from an attach statement:
58
- @@ -103210 ,11 +103249 ,8 @@ static void attachFunc(
58
+ @@ -106120 ,11 +106159 ,8 @@ static void attachFunc(
59
59
rc = SQLITE_NOMEM_BKPT;
60
60
}
61
61
@@ -67,7 +67,7 @@ index f077152..98f1857 100644
67
67
int nKey;
68
68
char *zKey;
69
69
int t = sqlite3_value_type(argv[2]);
70
- @@ -118241 ,6 +118277 ,11 @@ SQLITE_PRIVATE void sqlite3Pragma(
70
+ @@ -121536 ,6 +121572 ,11 @@ SQLITE_PRIVATE void sqlite3Pragma(
71
71
Db *pDb; /* The specific database being pragmaed */
72
72
Vdbe *v = sqlite3GetVdbe(pParse); /* Prepared statement */
73
73
const PragmaName *pPragma; /* The pragma */
@@ -79,7 +79,7 @@ index f077152..98f1857 100644
79
79
80
80
if( v==0 ) return;
81
81
sqlite3VdbeRunOnlyOnce(v);
82
- @@ -118311 ,6 +118352 ,15 @@ SQLITE_PRIVATE void sqlite3Pragma(
82
+ @@ -121606 ,6 +121647 ,15 @@ SQLITE_PRIVATE void sqlite3Pragma(
83
83
goto pragma_out;
84
84
}
85
85
@@ -95,15 +95,15 @@ index f077152..98f1857 100644
95
95
/* Locate the pragma in the lookup table */
96
96
pPragma = pragmaLocate(zLeft);
97
97
if( pPragma==0 ) goto pragma_out;
98
- @@ -130408 ,7 +130458 ,6 @@ SQLITE_PRIVATE int sqlite3RunVacuum(char **pzErrMsg, sqlite3 *db, int iDb){
98
+ @@ -134118 ,7 +134168 ,6 @@ SQLITE_PRIVATE SQLITE_NOINLINE int sqlite3RunVacuum(
99
99
/* A VACUUM cannot change the pagesize of an encrypted database. */
100
100
#ifdef SQLITE_HAS_CODEC
101
101
if( db->nextPagesize ){
102
102
- extern void sqlite3CodecGetKey(sqlite3*, int, void**, int*);
103
103
int nKey;
104
104
char *zKey;
105
105
sqlite3CodecGetKey(db, iDb, (void**)&zKey, &nKey);
106
- @@ -212222 ,3 +212271 ,2569 @@ int sqlite3_user_delete(
106
+ @@ -223234 ,3 +223283 ,2569 @@ int sqlite3_user_delete(
107
107
}
108
108
109
109
#endif /* SQLITE_USER_AUTHENTICATION */
@@ -1594,8 +1594,8 @@ index f077152..98f1857 100644
1594
1594
+ pSrc = pDb->pBt;
1595
1595
+
1596
1596
+ rc = sqlite3_exec(db, "BEGIN;", NULL, NULL, NULL);
1597
- + rc = sqlite3BtreeBeginTrans(pSrc, 2);
1598
- + rc = sqlite3BtreeBeginTrans(pDest, 2);
1597
+ + rc = sqlite3BtreeBeginTrans(pSrc, 2, 0 );
1598
+ + rc = sqlite3BtreeBeginTrans(pDest, 2, 0 );
1599
1599
+
1600
1600
+ assert( 1==sqlite3BtreeIsInTrans(pDest) );
1601
1601
+ assert( 1==sqlite3BtreeIsInTrans(pSrc) );
@@ -2413,7 +2413,7 @@ index f077152..98f1857 100644
2413
2413
+ ** 3. If that goes ok then commit and put ctx->rekey into ctx->key
2414
2414
+ ** note: don't deallocate rekey since it may be used in a subsequent iteration
2415
2415
+ */
2416
- + rc = sqlite3BtreeBeginTrans(pDb->pBt, 1); /* begin write transaction */
2416
+ + rc = sqlite3BtreeBeginTrans(pDb->pBt, 1, 0 ); /* begin write transaction */
2417
2417
+ sqlite3PagerPagecount(pPager, &page_count);
2418
2418
+ for(pgno = 1; rc == SQLITE_OK && pgno <= (unsigned int)page_count; pgno++) { /* pgno's start at 1 see pager.c:pagerAcquire */
2419
2419
+ if(!sqlite3pager_is_mj_pgno(pPager, pgno)) { /* skip this page (see pager.c:pagerAcquire for reasoning) */
0 commit comments