diff --git a/manifest b/manifest index b0f2690b3b..dda8425088 100644 --- a/manifest +++ b/manifest @@ -1,5 +1,5 @@ -C Merge\sall\sthe\slatest\strunk\schanges\sinto\sthe\ssessions\sbranch. -D 2013-03-06T02:12:18.694 +C Merge\srecent\schanges\sto\strunk\sinto\ssessions\sbranch. +D 2013-03-12T11:38:59.574 F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f F Makefile.in 9a804abbd3cae82d196e4d33aba13239e32522a5 F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23 @@ -133,7 +133,7 @@ F src/auth.c 523da7fb4979469955d822ff9298352d6b31de34 F src/backup.c b2cac9f7993f3f9588827b824b1501d0c820fa68 F src/bitvec.c 26675fe8e431dc555e6f2d0e11e651d172234aa1 F src/btmutex.c 976f45a12e37293e32cae0281b15a21d48a8aaa7 -F src/btree.c c7ce6045f023ba6426d5cca63fab5e1e3d282309 +F src/btree.c 746c4dafae8565b3be6fb9ce3bb1fa9f1e67cc59 F src/btree.h 3ad7964d6c5b1c7bff569aab6adfa075f8bf06cd F src/btreeInt.h eecc84f02375b2bb7a44abbcbbe3747dde73edb2 F src/build.c 375e5df716e03b9343c5e1211be3b24e6d6dff05 @@ -141,11 +141,11 @@ F src/callback.c d7e46f40c3cf53c43550b7da7a1d0479910b62cc F src/complete.c dc1d136c0feee03c2f7550bafc0d29075e36deac F src/ctime.c 72a70dcfda75d3a1f81041ce4573e7afddcd8e4e F src/date.c 067a81c9942c497aafd2c260e13add8a7d0c7dd4 -F src/delete.c 9bc9463952bdc9fc43111b1f9c83a0af9b8e2239 +F src/delete.c 39a770e9729b1acd2de347f8f614584841d0083e F src/expr.c a23b4aac2a455b2e76b55bef5dcfbe62b665375c F src/fault.c 160a0c015b6c2629d3899ed2daf63d75754a32bb F src/fkey.c e16942bd5c8a868ac53287886464a5ed0e72b179 -F src/func.c 91bc65eb68ef6cf29198aac92f11489fa85a8de4 +F src/func.c 48987c025d69399f59a1c2a553cea5da41bf105d F src/global.c e59ecd2c553ad0d4bfbc84ca71231336f8993a7a F src/hash.c ac3470bbf1ca4ae4e306a8ecb0fdf1731810ffe4 F src/hash.h 2894c932d84d9f892d4b4023a75e501f83050970 @@ -180,8 +180,8 @@ F src/parse.y 5d5e12772845805fdfeb889163516b84fbb9ae95 F src/pcache.c f8043b433a57aba85384a531e3937a804432a346 F src/pcache.h 1b5dcc3dc8103d03e625b177023ee67764fa6b7c F src/pcache1.c 9fd22671c270b35131ef480bbc00392b8b5f8ab9 -F src/pragma.c bdb484d0283965c431d4153f28c30f836a1f16b1 -F src/prepare.c 931ad0d852a0df48f79adcba6ce79ca5f475625c +F src/pragma.c 9f0ee3d74a7f33eeeff40a4b014fc3abf8182ce2 +F src/prepare.c 78cd7ae8cd0d8de8ef8a8b5352fc5f38693a0852 F src/printf.c 4a9f882f1c1787a8b494a2987765acf9d97ac21f F src/random.c cd4a67b3953b88019f8cd4ccd81394a8ddfaba50 F src/resolve.c 9079da7d59aed2bb14ec8315bc7f720dd85b5b65 @@ -191,7 +191,7 @@ F src/shell.c 7c41bfcd9e5bf9d96b9215f79b03a5b2b44a3bca F src/sqlite.h.in 7c9b66c397025a9e93e1ec1faa03324b757a2880 F src/sqlite3.rc fea433eb0a59f4c9393c8e6d76a6e2596b1fe0c0 F src/sqlite3ext.h 7183ab832e23db0f934494f16928da127a571d75 -F src/sqliteInt.h 4b854bf7da123c2bab96664afaac8d14e6027524 +F src/sqliteInt.h 8515d149d4b20fb89d4c5bd2ce57f005e4ced42f F src/sqliteLimit.h 164b0e6749d31e0daa1a4589a169d31c0dec7b3d F src/status.c bedc37ec1a6bb9399944024d63f4c769971955a9 F src/table.c 2cd62736f845d82200acfa1287e33feb3c15d62e @@ -257,7 +257,7 @@ F src/vdbeInt.h 0112cab1c820a599005c6bcc9504bdb17f5dbcdb F src/vdbeapi.c b816227ece97354aee7a741c1fc3c5445202d8bb F src/vdbeaux.c 684c159170453c8a118786b9c174627ece825f3a F src/vdbeblob.c 11248c6362389569764682eb0f59ce910f3cc381 -F src/vdbemem.c cb55e84b8e2c15704968ee05f0fae25883299b74 +F src/vdbemem.c 833005f1cbbf447289f1973dba2a0c2228c7b8ab F src/vdbesort.c c61ca318681c0e7267da8be3abfca8469652a7e9 F src/vdbetrace.c 8bd5da325fc90f28464335e4cc4ad1407fe30835 F src/vtab.c b05e5f1f4902461ba9f5fc49bb7eb7c3a0741a83 @@ -293,7 +293,7 @@ F test/attach2.test e54436ed956d3d88bdee61221da59bf3935a0966 F test/attach3.test d89ccfe4fe6e2b5e368d480fcdfe4b496c54cf4e F test/attach4.test 53bf502f17647c6d6c5add46dda6bac8b6f4665c F test/attachmalloc.test 3a4bfca9545bfe906a8d2e622de10fbac5b711b0 -F test/auth.test 304e82f31592820d3bde26ab6b75deaa123e1a6f +F test/auth.test 1b21145e888130d60a03db0cb829d59df8f29266 F test/auth2.test a2a371aa6df15f8b0c8109b33d3d7f0f73e4c9aa F test/auth3.test a4755e6a2a2fea547ffe63c874eb569e60a28eb5 F test/autoinc.test bd30d372d00045252f6c2e41b5f41455e1975acf @@ -474,7 +474,7 @@ F test/fts3ae.test ce32a13b34b0260928e4213b4481acf801533bda F test/fts3af.test d394978c534eabf22dd0837e718b913fd66b499c F test/fts3ag.test 0b7d303f61ae5d620c4efb5e825713ea34ff9441 F test/fts3ah.test dc9f66c32c296f1bc8bcc4535126bddfeca62894 -F test/fts3ai.test d29cee6ed653e30de478066881cec8aa766531b2 +F test/fts3ai.test 24058fdc6e9e5102c1fd8459591b114b6a85d285 F test/fts3aj.test 0ed71e1dd9b03b843a857dc3eb9b15630e0104fc F test/fts3ak.test bd14deafe9d1586e8e9bf032411026ac4f8c925d F test/fts3al.test 07d64326e79bbdbab20ee87fc3328fbf01641c9f @@ -547,7 +547,7 @@ F test/incrblobfault.test 917c0292224c64a56ef7215fd633a3a82f805be0 F test/incrvacuum.test d2a6ddf5e429720b5fe502766af747915ccf6c32 F test/incrvacuum2.test 379eeb8740b0ef60c372c439ad4cbea20b34bb9b F test/incrvacuum3.test 2ffa9e4a23f072bd7902b9ae6471f8822a6522a7 -F test/incrvacuum_ioerr.test 293f2714571255539c8c789da2f7de4ec3f7101e +F test/incrvacuum_ioerr.test 6ae2f783424e47a0033304808fe27789cf93e635 F test/index.test b5429732b3b983fa810e3ac867d7ca85dae35097 F test/index2.test ee83c6b5e3173a3d7137140d945d9a5d4fdfb9d6 F test/index3.test 423a25c789fc8cc51aaf2a4370bbdde2d9e9eed7 @@ -571,7 +571,7 @@ F test/ioerr2.test 9d71166f8466eda510f1af6137bdabaa82b5408d F test/ioerr3.test d3cec5e1a11ad6d27527d0d38573fbff14c71bdd F test/ioerr4.test f130fe9e71008577b342b8874d52984bd04ede2c F test/ioerr5.test 2edfa4fb0f896f733071303b42224df8bedd9da4 -F test/ioerr6.test 13f0f9c31d706f0dd575995c369af07c0227e9a2 +F test/ioerr6.test cf25523b921d1a6a0e5b536cd4acb3c3d979ea52 F test/join.test 8d63cc4d230a7affafa4b6ab0b97c49b8ccb365c F test/join2.test f2171c265e57ee298a27e57e7051d22962f9f324 F test/join3.test 6f0c774ff1ba0489e6c88a3e77b9d3528fb4fda0 @@ -618,7 +618,7 @@ F test/mallocC.test 3dffe16532f109293ce1ccecd0c31dca55ef08c4 F test/mallocD.test f78c295e8e18ea3029e65ca08278690e00c22100 F test/mallocE.test db1ed69d7eded1b080952e2a7c37f364ad241b08 F test/mallocF.test 2d5c590ebc2fc7f0dcebdf5aa8498b9aed69107e -F test/mallocG.test 4584d0d8ddb8009f16ca0c8bab1fa37f6358efa2 +F test/mallocG.test 0ff91b65c50bdaba680fb75d87fe4ad35bb7934f F test/mallocH.test 79b65aed612c9b3ed2dcdaa727c85895fd1bfbdb F test/mallocI.test a88c2b9627c8506bf4703d8397420043a786cdb6 F test/mallocJ.test b5d1839da331d96223e5f458856f8ffe1366f62e @@ -922,7 +922,7 @@ F test/trigger6.test 0e411654f122552da6590f0b4e6f781048a4a9b9 F test/trigger7.test b39e6dee1debe0ff9c2ef66326668f149f07c9c4 F test/trigger8.test 30cb0530bd7c4728055420e3f739aa00412eafa4 F test/trigger9.test 5b0789f1c5c4600961f8e68511b825b87be53e31 -F test/triggerA.test e0aaba16d3547193d36bbd82a1b0ed75e9c88d40 +F test/triggerA.test fe5597f47ee21bacb4936dc827994ed94161e332 F test/triggerB.test 56780c031b454abac2340dbb3b71ac5c56c3d7fe F test/triggerC.test a7b4367392c755bc5fd5fff88011753e6b6afe90 F test/triggerD.test 8e7f3921a92a5797d472732108109e44575fa650 @@ -1050,7 +1050,7 @@ F tool/vdbe-compress.tcl f12c884766bd14277f4fcedcae07078011717381 F tool/warnings-clang.sh f6aa929dc20ef1f856af04a730772f59283631d4 F tool/warnings.sh fbc018d67fd7395f440c28f33ef0f94420226381 F tool/win/sqlite.vsix 97894c2790eda7b5bce3cc79cb2a8ec2fde9b3ac -P 7e14dc734d7d941da5c3aa6612e26d93b5b929bd 7097241c1220ada318f8eda938c3e3430b94a606 -R e469c56b0b932202c050a14daa3532bb -U drh -Z a8cbf1c861240eb4a7fc756e2ad3beac +P d69d21903b883067c66dbcdefe6b369a6fe328b0 f9027cb47bdec8dcebf1f038921b28d9e9928c18 +R f222f57c93ab273cf35121a2470c5e52 +U dan +Z c5f2b4d72ddf45f3699f5c346c8949b7 diff --git a/manifest.uuid b/manifest.uuid index 9a0a84d2e1..a0ef93ed7e 100644 --- a/manifest.uuid +++ b/manifest.uuid @@ -1 +1 @@ -d69d21903b883067c66dbcdefe6b369a6fe328b0 \ No newline at end of file +62adb0e0d70e619becb68ffd2625d979bcc777cd \ No newline at end of file diff --git a/src/btree.c b/src/btree.c index 16b56f5bf0..07ec3fe52a 100644 --- a/src/btree.c +++ b/src/btree.c @@ -43,6 +43,25 @@ int sqlite3BtreeTrace=1; /* True to enable tracing */ */ #define get2byteNotZero(X) (((((int)get2byte(X))-1)&0xffff)+1) +/* +** Values passed as the 5th argument to allocateBtreePage() +*/ +#define BTALLOC_ANY 0 /* Allocate any page */ +#define BTALLOC_EXACT 1 /* Allocate exact page if possible */ +#define BTALLOC_LE 2 /* Allocate any page <= the parameter */ + +/* +** Macro IfNotOmitAV(x) returns (x) if SQLITE_OMIT_AUTOVACUUM is not +** defined, or 0 if it is. For example: +** +** bIncrVacuum = IfNotOmitAV(pBtShared->incrVacuum); +*/ +#ifndef SQLITE_OMIT_AUTOVACUUM +#define IfNotOmitAV(expr) (expr) +#else +#define IfNotOmitAV(expr) 0 +#endif + #ifndef SQLITE_OMIT_SHARED_CACHE /* ** A list of BtShared objects that are eligible for participation @@ -2595,7 +2614,7 @@ int sqlite3BtreeBeginTrans(Btree *p, int wrflag){ if( p->inTrans==TRANS_WRITE || (p->inTrans==TRANS_READ && !wrflag) ){ goto trans_begun; } - assert( pBt->bDoTruncate==0 ); + assert( IfNotOmitAV(pBt->bDoTruncate)==0 ); /* Write transactions are not possible on a read-only database */ if( (pBt->btsFlags & BTS_READ_ONLY)!=0 && wrflag ){ @@ -2910,9 +2929,6 @@ static int relocatePage( /* Forward declaration required by incrVacuumStep(). */ static int allocateBtreePage(BtShared *, MemPage **, Pgno *, Pgno, u8); -#define BTALLOC_ANY 0 /* Allocate any page */ -#define BTALLOC_EXACT 1 /* Allocate exact page if possible */ -#define BTALLOC_LE 2 /* Allocate any page <= the parameter */ /* ** Perform a single step of an incremental-vacuum. If successful, return @@ -4902,7 +4918,7 @@ static int allocateBtreePage( Pgno mxPage; /* Total size of the database file */ assert( sqlite3_mutex_held(pBt->mutex) ); - assert( eMode==BTALLOC_ANY || (nearby>0 && pBt->autoVacuum) ); + assert( eMode==BTALLOC_ANY || (nearby>0 && IfNotOmitAV(pBt->autoVacuum)) ); pPage1 = pBt->pPage1; mxPage = btreePagecount(pBt); n = get4byte(&pPage1->aData[36]); @@ -5135,7 +5151,7 @@ static int allocateBtreePage( ** here are confined to those pages that lie between the end of the ** database image and the end of the database file. */ - int bNoContent = (0==pBt->bDoTruncate); + int bNoContent = (0==IfNotOmitAV(pBt->bDoTruncate)); rc = sqlite3PagerWrite(pBt->pPage1->pDbPage); if( rc ) return rc; diff --git a/src/delete.c b/src/delete.c index 8bca679510..0bd9496d6f 100644 --- a/src/delete.c +++ b/src/delete.c @@ -93,30 +93,28 @@ void sqlite3MaterializeView( int iCur /* Cursor number for ephemerial table */ ){ SelectDest dest; - Select *pDup; + Select *pSel; + SrcList *pFrom; sqlite3 *db = pParse->db; + int iDb = sqlite3SchemaToIndex(db, pView->pSchema); - pDup = sqlite3SelectDup(db, pView->pSelect, 0); - if( pWhere ){ - SrcList *pFrom; - - pWhere = sqlite3ExprDup(db, pWhere, 0); - pFrom = sqlite3SrcListAppend(db, 0, 0, 0); - if( pFrom ){ - assert( pFrom->nSrc==1 ); - pFrom->a[0].zAlias = sqlite3DbStrDup(db, pView->zName); - pFrom->a[0].pSelect = pDup; - assert( pFrom->a[0].pOn==0 ); - assert( pFrom->a[0].pUsing==0 ); - }else{ - sqlite3SelectDelete(db, pDup); - } - pDup = sqlite3SelectNew(pParse, 0, pFrom, pWhere, 0, 0, 0, 0, 0, 0); - if( pDup ) pDup->selFlags |= SF_Materialize; + pWhere = sqlite3ExprDup(db, pWhere, 0); + pFrom = sqlite3SrcListAppend(db, 0, 0, 0); + + if( pFrom ){ + assert( pFrom->nSrc==1 ); + pFrom->a[0].zName = sqlite3DbStrDup(db, pView->zName); + pFrom->a[0].zDatabase = sqlite3DbStrDup(db, db->aDb[iDb].zName); + assert( pFrom->a[0].pOn==0 ); + assert( pFrom->a[0].pUsing==0 ); } + + pSel = sqlite3SelectNew(pParse, 0, pFrom, pWhere, 0, 0, 0, 0, 0, 0); + if( pSel ) pSel->selFlags |= SF_Materialize; + sqlite3SelectDestInit(&dest, SRT_EphemTab, iCur); - sqlite3Select(pParse, pDup, &dest); - sqlite3SelectDelete(db, pDup); + sqlite3Select(pParse, pSel, &dest); + sqlite3SelectDelete(db, pSel); } #endif /* !defined(SQLITE_OMIT_VIEW) && !defined(SQLITE_OMIT_TRIGGER) */ diff --git a/src/func.c b/src/func.c index 56cd6052b4..0fce95904f 100644 --- a/src/func.c +++ b/src/func.c @@ -999,18 +999,23 @@ static void charFunc( x = sqlite3_value_int64(argv[i]); if( x<0 || x>0x10ffff ) x = 0xfffd; c = (unsigned)(x & 0x1fffff); - if( c<=0xFFFF ){ - if( c>=0xd800 && c<=0xdfff ) c = 0xfffd; - *zOut++ = (u8)(c&0x00FF); - *zOut++ = (u8)((c>>8)&0x00FF); + if( c<0x00080 ){ + *zOut++ = (u8)(c&0xFF); + }else if( c<0x00800 ){ + *zOut++ = 0xC0 + (u8)((c>>6)&0x1F); + *zOut++ = 0x80 + (u8)(c & 0x3F); + }else if( c<0x10000 ){ + *zOut++ = 0xE0 + (u8)((c>>12)&0x0F); + *zOut++ = 0x80 + (u8)((c>>6) & 0x3F); + *zOut++ = 0x80 + (u8)(c & 0x3F); }else{ - *zOut++ = (u8)(((c>>10)&0x003F) + (((c-0x10000)>>10)&0x00C0)); - *zOut++ = (u8)(0x00D8 + (((c-0x10000)>>18)&0x03)); - *zOut++ = (u8)(c&0x00FF); - *zOut++ = (u8)(0x00DC + ((c>>8)&0x03)); - } + *zOut++ = 0xF0 + (u8)((c>>18) & 0x07); + *zOut++ = 0x80 + (u8)((c>>12) & 0x3F); + *zOut++ = 0x80 + (u8)((c>>6) & 0x3F); + *zOut++ = 0x80 + (u8)(c & 0x3F); + } \ } - sqlite3_result_text16le(context, (char*)z, (int)(zOut-z), sqlite3_free); + sqlite3_result_text(context, (char*)z, (int)(zOut-z), sqlite3_free); } /* diff --git a/src/pragma.c b/src/pragma.c index 9927c50f2a..f6dadbd4a8 100644 --- a/src/pragma.c +++ b/src/pragma.c @@ -1130,6 +1130,7 @@ void sqlite3Pragma( #endif /* !defined(SQLITE_OMIT_FOREIGN_KEY) */ #ifndef SQLITE_OMIT_FOREIGN_KEY +#ifndef SQLITE_OMIT_TRIGGER if( sqlite3StrICmp(zLeft, "foreign_key_check")==0 ){ FKey *pFK; /* A foreign key constraint */ Table *pTab; /* Child table contain "REFERENCES" keyword */ @@ -1241,6 +1242,7 @@ void sqlite3Pragma( sqlite3VdbeJumpHere(v, addrTop); } }else +#endif /* !defined(SQLITE_OMIT_TRIGGER) */ #endif /* !defined(SQLITE_OMIT_FOREIGN_KEY) */ #ifndef NDEBUG diff --git a/src/prepare.c b/src/prepare.c index 5ac8de7296..21a12f32cb 100644 --- a/src/prepare.c +++ b/src/prepare.c @@ -259,11 +259,15 @@ static int sqlite3InitOne(sqlite3 *db, int iDb, char **pzErrMsg){ */ if( meta[BTREE_TEXT_ENCODING-1] ){ /* text encoding */ if( iDb==0 ){ +#ifndef SQLITE_OMIT_UTF16 u8 encoding; /* If opening the main database, set ENC(db). */ encoding = (u8)meta[BTREE_TEXT_ENCODING-1] & 3; if( encoding==0 ) encoding = SQLITE_UTF8; ENC(db) = encoding; +#else + ENC(db) = SQLITE_UTF8; +#endif }else{ /* If opening an attached database, the encoding much match ENC(db) */ if( meta[BTREE_TEXT_ENCODING-1]!=ENC(db) ){ diff --git a/src/sqliteInt.h b/src/sqliteInt.h index 06d7f663b7..6eede813a9 100644 --- a/src/sqliteInt.h +++ b/src/sqliteInt.h @@ -66,6 +66,10 @@ # define _GNU_SOURCE #endif +#if defined(__OpenBSD__) && !defined(_BSD_SOURCE) +# define _BSD_SOURCE +#endif + /* ** Include standard header files as necessary */ diff --git a/src/vdbemem.c b/src/vdbemem.c index fd964de2e9..8fc222e2de 100644 --- a/src/vdbemem.c +++ b/src/vdbemem.c @@ -32,7 +32,9 @@ ** between formats. */ int sqlite3VdbeChangeEncoding(Mem *pMem, int desiredEnc){ +#ifndef SQLITE_OMIT_UTF16 int rc; +#endif assert( (pMem->flags&MEM_RowSet)==0 ); assert( desiredEnc==SQLITE_UTF8 || desiredEnc==SQLITE_UTF16LE || desiredEnc==SQLITE_UTF16BE ); diff --git a/test/auth.test b/test/auth.test index 211ae7e21c..190b490003 100644 --- a/test/auth.test +++ b/test/auth.test @@ -2262,7 +2262,9 @@ do_test auth-4.3 { SQLITE_SELECT {} {} {} v1 \ SQLITE_READ t2 a main v1 \ SQLITE_READ t2 b main v1 \ - SQLITE_SELECT {} {} {} {} \ + SQLITE_READ v1 x main v1 \ + SQLITE_READ v1 x main v1 \ + SQLITE_SELECT {} {} {} v1 \ SQLITE_READ v1 x main v1 \ SQLITE_INSERT v1chng {} main r2 \ SQLITE_READ v1 x main r2 \ @@ -2288,7 +2290,9 @@ do_test auth-4.5 { SQLITE_SELECT {} {} {} v1 \ SQLITE_READ t2 a main v1 \ SQLITE_READ t2 b main v1 \ - SQLITE_SELECT {} {} {} {} \ + SQLITE_READ v1 x main v1 \ + SQLITE_READ v1 x main v1 \ + SQLITE_SELECT {} {} {} v1 \ SQLITE_READ v1 x main v1 \ SQLITE_INSERT v1chng {} main r3 \ SQLITE_READ v1 x main r3 \ diff --git a/test/fts3ai.test b/test/fts3ai.test index 144b4c3ef4..b17b5bdd55 100644 --- a/test/fts3ai.test +++ b/test/fts3ai.test @@ -19,6 +19,11 @@ ifcapable !fts3 { return } +ifcapable !utf16 { + finish_test + return +} + # Return the UTF-16 representation of the supplied UTF-8 string $str. # If $nt is true, append two 0x00 bytes as a nul terminator. # NOTE(shess) Copied from capi3.test. diff --git a/test/incrvacuum_ioerr.test b/test/incrvacuum_ioerr.test index aecb6f8747..50f7fa2029 100644 --- a/test/incrvacuum_ioerr.test +++ b/test/incrvacuum_ioerr.test @@ -141,6 +141,7 @@ ifcapable shared_cache { # set nFree [execsql {pragma freelist_count} db1] set nPage [execsql {pragma page_count} db1] + puts "nFree=$nFree nPage=$nPage" # Now run incremental-vacuum to vacuum 5 pages from the db file. # The iTest'th I/O call is set to fail. @@ -162,7 +163,7 @@ ifcapable shared_cache { do_test incrvacuum-ioerr-4.$iTest.2 { set shrink [expr {$nPage-$nPage2}] - expr {$shrink==0 || $shrink==5} + expr {$shrink==0 || $shrink==5 || ($nFree<5 && $shrink==$nFree)} } {1} do_test incrvacuum-ioerr-4.$iTest.3 { diff --git a/test/ioerr6.test b/test/ioerr6.test index d2f10b142d..66c48ad2e8 100644 --- a/test/ioerr6.test +++ b/test/ioerr6.test @@ -20,6 +20,15 @@ ifcapable !atomicwrite { finish_test return } + +if {[permutation]=="inmemory_journal"} { + # These tests will not work with in-memory journals (as persistent VFS + # errors commencing after a transaction has started to write to the db + # cannot be recovered from). + finish_test + return +} + faultsim_save_and_close do_test 1.1 { @@ -63,7 +72,7 @@ do_faultsim_test 2 -faults full* -prep { } } -do_faultsim_test 2 -faults full* -prep { +do_faultsim_test 3 -faults full* -prep { shmfault devchar atomic faultsim_restore sqlite3 db test.db diff --git a/test/mallocG.test b/test/mallocG.test index eab533b5b3..4f2395db9c 100644 --- a/test/mallocG.test +++ b/test/mallocG.test @@ -53,6 +53,11 @@ do_malloc_test mallocG-3 -sqlprep { AND x BETWEEN 'i' AND 'm' } +ifcapable !utf16 { + finish_test + return +} + proc utf16 {utf8} { set utf16 [encoding convertto unicode $utf8] append utf16 "\x00\x00" diff --git a/test/triggerA.test b/test/triggerA.test index 0bc017ff5e..821e2d90e4 100644 --- a/test/triggerA.test +++ b/test/triggerA.test @@ -192,6 +192,13 @@ do_test triggerA-2.10 { SELECT * FROM result4 ORDER BY a; } } {3 305 3 9900305 4 404 4 9900404 5 504 5 9900504} +do_test triggerA-2.11 { + db eval { + DELETE FROM result4; + UPDATE v5 SET b = main.v5.b+9900000 WHERE main.v5.x BETWEEN 3 AND 5; + SELECT * FROM result4 ORDER BY a; + } +} {3 305 3 9900305 4 404 4 9900404 5 504 5 9900504} # Only run the reamining tests if memory debugging is turned on. #