Updated to fix compatibility with sqlite 3.6.13

- Removed Makefile's inclusion of backup.h (removed from distro)
- update for new sqlite3BtreeSetPageSize iFix parameter
This commit is contained in:
Stephen Lombardo
2009-04-21 12:00:30 -04:00
parent 6737773707
commit 59ef6e1f46
2 changed files with 2 additions and 3 deletions
-1
View File
@@ -408,7 +408,6 @@ TESTSRC = \
#
HDR = \
sqlite3.h \
$(TOP)/src/backup.h \
$(TOP)/src/btree.h \
$(TOP)/src/btreeInt.h \
$(TOP)/src/hash.h \
+2 -2
View File
@@ -190,7 +190,7 @@ int sqlite3CodecAttach(sqlite3* db, int nDb, const void *zKey, int nKey) {
if(ctx->key == NULL) return SQLITE_NOMEM;
memcpy(ctx->key, zKey, nKey);
sqlite3BtreeSetPageSize(ctx->pBt, sqlite3BtreeGetPageSize(ctx->pBt), ctx->iv_sz);
sqlite3BtreeSetPageSize(ctx->pBt, sqlite3BtreeGetPageSize(ctx->pBt), ctx->iv_sz, 0);
sqlite3PagerSetCodec(sqlite3BtreePager(pDb->pBt), sqlite3Codec, (void *) ctx);
return SQLITE_OK;
}
@@ -286,7 +286,7 @@ int sqlite3_rekey(sqlite3 *db, const void *pKey, int nKey) {
char *error;
db->nextPagesize = sqlite3BtreeGetPageSize(pDb->pBt);
pDb->pBt->pBt->pageSizeFixed = 0; /* required for sqlite3BtreeSetPageSize to modify pagesize setting */
sqlite3BtreeSetPageSize(pDb->pBt, db->nextPagesize, EVP_CIPHER_iv_length(CIPHER));
sqlite3BtreeSetPageSize(pDb->pBt, db->nextPagesize, EVP_CIPHER_iv_length(CIPHER), 0);
sqlite3RunVacuum(&error, db);
sqlite3CodecAttach(db, i, key, prepared_key_sz);
sqlite3pager_get_codec(pDb->pBt->pBt->pPager, (void **) &ctx);