aboutsummaryrefslogtreecommitdiffstats
path: root/contrib/libs/sqlite3
diff options
context:
space:
mode:
authorarcadia-devtools <arcadia-devtools@yandex-team.ru>2022-03-28 09:11:10 +0300
committerarcadia-devtools <arcadia-devtools@yandex-team.ru>2022-03-28 09:11:10 +0300
commit48af3ac5acb68ca98e56db49d1d6361e77939d3b (patch)
treea70013f0dd7fe1611ff3116a81049e81e8898e88 /contrib/libs/sqlite3
parent89c3ea4758ef1b8ee05865c7691327ca8c6db81f (diff)
downloadydb-48af3ac5acb68ca98e56db49d1d6361e77939d3b.tar.gz
intermediate changes
ref:1a63b74b61c8b2de44dfe7402fcceaa40fd8b450
Diffstat (limited to 'contrib/libs/sqlite3')
-rw-r--r--contrib/libs/sqlite3/.yandex_meta/devtools.licenses.report204
-rw-r--r--contrib/libs/sqlite3/config.h4
-rw-r--r--contrib/libs/sqlite3/sqlite3.c145
-rw-r--r--contrib/libs/sqlite3/sqlite3.h6
4 files changed, 208 insertions, 151 deletions
diff --git a/contrib/libs/sqlite3/.yandex_meta/devtools.licenses.report b/contrib/libs/sqlite3/.yandex_meta/devtools.licenses.report
index 7858920149e..528c9a3014c 100644
--- a/contrib/libs/sqlite3/.yandex_meta/devtools.licenses.report
+++ b/contrib/libs/sqlite3/.yandex_meta/devtools.licenses.report
@@ -39,7 +39,7 @@ BELONGS ya.make
Match type : TEXT
Links : http://www.linfo.org/publicdomain.html, https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/licenses/public-domain.LICENSE
Files with this license:
- sqlite3.c [173937:173937]
+ sqlite3.c [173994:173994]
SKIP LicenseRef-scancode-proprietary-license 8426a059ede424b00bf0246f20b5d31f
BELONGS ya.make
@@ -52,7 +52,7 @@ BELONGS ya.make
Match type : REFERENCE
Links : https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/licenses/proprietary-license.LICENSE
Files with this license:
- sqlite3.c [65523:65523]
+ sqlite3.c [65533:65533]
KEEP blessing 85b808eb169d4456ed67e0cf819b320f
BELONGS ya.make
@@ -105,105 +105,105 @@ BELONGS ya.make
sqlite3.c [32593:32598]
sqlite3.c [34311:34316]
sqlite3.c [34787:34792]
- sqlite3.c [42919:42924]
- sqlite3.c [49076:49081]
- sqlite3.c [49957:49962]
- sqlite3.c [50371:50376]
- sqlite3.c [51260:51265]
- sqlite3.c [52547:52552]
- sqlite3.c [53052:53057]
- sqlite3.c [53076:53081]
- sqlite3.c [60947:60952]
- sqlite3.c [65105:65110]
- sqlite3.c [65124:65129]
- sqlite3.c [66151:66156]
- sqlite3.c [77068:77073]
- sqlite3.c [77841:77846]
- sqlite3.c [79787:79792]
- sqlite3.c [85049:85054]
- sqlite3.c [87190:87195]
- sqlite3.c [87385:87390]
- sqlite3.c [95993:95998]
- sqlite3.c [96512:96517]
- sqlite3.c [99281:99286]
- sqlite3.c [99708:99713]
- sqlite3.c [100149:100154]
- sqlite3.c [100409:100414]
- sqlite3.c [102468:102473]
- sqlite3.c [108821:108826]
- sqlite3.c [111084:111089]
- sqlite3.c [113017:113022]
- sqlite3.c [113618:113623]
- sqlite3.c [113889:113894]
- sqlite3.c [119533:119538]
- sqlite3.c [120073:120078]
- sqlite3.c [121058:121063]
- sqlite3.c [123444:123449]
- sqlite3.c [124923:124928]
- sqlite3.c [128054:128059]
- sqlite3.c [128198:128203]
- sqlite3.c [128218:128223]
- sqlite3.c [129770:129775]
- sqlite3.c [133156:133161]
- sqlite3.c [134213:134218]
- sqlite3.c [141765:141770]
- sqlite3.c [141965:141970]
- sqlite3.c [143397:143402]
- sqlite3.c [144737:144742]
- sqlite3.c [145055:145060]
- sqlite3.c [145464:145469]
- sqlite3.c [146810:146815]
- sqlite3.c [146832:146837]
- sqlite3.c [150154:150159]
- sqlite3.c [151994:151999]
- sqlite3.c [158190:158195]
- sqlite3.c [161300:161305]
- sqlite3.c [166710:166715]
- sqlite3.c [168051:168056]
- sqlite3.c [168344:168349]
- sqlite3.c [168365:168370]
- sqlite3.c [168398:168403]
- sqlite3.c [168435:168440]
- sqlite3.c [173264:173269]
- sqlite3.c [173599:173604]
- sqlite3.c [173891:173896]
- sqlite3.c [174103:174108]
- sqlite3.c [180655:180660]
- sqlite3.c [181214:181219]
- sqlite3.c [182510:182515]
- sqlite3.c [182896:182901]
- sqlite3.c [183561:183566]
- sqlite3.c [184084:184089]
- sqlite3.c [184321:184326]
- sqlite3.c [184782:184787]
- sqlite3.c [190594:190599]
- sqlite3.c [192348:192353]
- sqlite3.c [192748:192753]
- sqlite3.c [193134:193139]
- sqlite3.c [195812:195817]
- sqlite3.c [200216:200221]
- sqlite3.c [202215:202220]
- sqlite3.c [202772:202777]
- sqlite3.c [203037:203042]
- sqlite3.c [203128:203133]
- sqlite3.c [208995:209000]
- sqlite3.c [209898:209903]
- sqlite3.c [216136:216141]
- sqlite3.c [216712:216717]
- sqlite3.c [217588:217593]
- sqlite3.c [219065:219070]
- sqlite3.c [219780:219785]
- sqlite3.c [220189:220194]
- sqlite3.c [221155:221160]
- sqlite3.c [224224:224229]
- sqlite3.c [224785:224790]
- sqlite3.c [231605:231610]
- sqlite3.c [234532:234537]
- sqlite3.c [235701:235706]
- sqlite3.c [237117:237122]
- sqlite3.c [237896:237901]
- sqlite3.c [238241:238246]
- sqlite3.c [239039:239044]
+ sqlite3.c [42925:42930]
+ sqlite3.c [49086:49091]
+ sqlite3.c [49967:49972]
+ sqlite3.c [50381:50386]
+ sqlite3.c [51270:51275]
+ sqlite3.c [52557:52562]
+ sqlite3.c [53062:53067]
+ sqlite3.c [53086:53091]
+ sqlite3.c [60957:60962]
+ sqlite3.c [65115:65120]
+ sqlite3.c [65134:65139]
+ sqlite3.c [66161:66166]
+ sqlite3.c [77081:77086]
+ sqlite3.c [77854:77859]
+ sqlite3.c [79800:79805]
+ sqlite3.c [85062:85067]
+ sqlite3.c [87203:87208]
+ sqlite3.c [87398:87403]
+ sqlite3.c [96006:96011]
+ sqlite3.c [96525:96530]
+ sqlite3.c [99294:99299]
+ sqlite3.c [99721:99726]
+ sqlite3.c [100162:100167]
+ sqlite3.c [100422:100427]
+ sqlite3.c [102481:102486]
+ sqlite3.c [108834:108839]
+ sqlite3.c [111097:111102]
+ sqlite3.c [113030:113035]
+ sqlite3.c [113631:113636]
+ sqlite3.c [113902:113907]
+ sqlite3.c [119546:119551]
+ sqlite3.c [120086:120091]
+ sqlite3.c [121071:121076]
+ sqlite3.c [123457:123462]
+ sqlite3.c [124936:124941]
+ sqlite3.c [128067:128072]
+ sqlite3.c [128211:128216]
+ sqlite3.c [128231:128236]
+ sqlite3.c [129783:129788]
+ sqlite3.c [133169:133174]
+ sqlite3.c [134226:134231]
+ sqlite3.c [141778:141783]
+ sqlite3.c [141978:141983]
+ sqlite3.c [143410:143415]
+ sqlite3.c [144750:144755]
+ sqlite3.c [145068:145073]
+ sqlite3.c [145477:145482]
+ sqlite3.c [146824:146829]
+ sqlite3.c [146846:146851]
+ sqlite3.c [150168:150173]
+ sqlite3.c [152008:152013]
+ sqlite3.c [158247:158252]
+ sqlite3.c [161357:161362]
+ sqlite3.c [166767:166772]
+ sqlite3.c [168108:168113]
+ sqlite3.c [168401:168406]
+ sqlite3.c [168422:168427]
+ sqlite3.c [168455:168460]
+ sqlite3.c [168492:168497]
+ sqlite3.c [173321:173326]
+ sqlite3.c [173656:173661]
+ sqlite3.c [173948:173953]
+ sqlite3.c [174160:174165]
+ sqlite3.c [180712:180717]
+ sqlite3.c [181271:181276]
+ sqlite3.c [182567:182572]
+ sqlite3.c [182953:182958]
+ sqlite3.c [183618:183623]
+ sqlite3.c [184141:184146]
+ sqlite3.c [184378:184383]
+ sqlite3.c [184839:184844]
+ sqlite3.c [190651:190656]
+ sqlite3.c [192405:192410]
+ sqlite3.c [192805:192810]
+ sqlite3.c [193191:193196]
+ sqlite3.c [195869:195874]
+ sqlite3.c [200273:200278]
+ sqlite3.c [202272:202277]
+ sqlite3.c [202829:202834]
+ sqlite3.c [203094:203099]
+ sqlite3.c [203185:203190]
+ sqlite3.c [209052:209057]
+ sqlite3.c [209955:209960]
+ sqlite3.c [216193:216198]
+ sqlite3.c [216769:216774]
+ sqlite3.c [217645:217650]
+ sqlite3.c [219122:219127]
+ sqlite3.c [219837:219842]
+ sqlite3.c [220246:220251]
+ sqlite3.c [221212:221217]
+ sqlite3.c [224281:224286]
+ sqlite3.c [224842:224847]
+ sqlite3.c [231662:231667]
+ sqlite3.c [234589:234594]
+ sqlite3.c [235758:235763]
+ sqlite3.c [237174:237179]
+ sqlite3.c [237953:237958]
+ sqlite3.c [238298:238303]
+ sqlite3.c [239096:239101]
sqlite3.h [4:9]
sqlite3.h [10392:10397]
sqlite3.h [12234:12239]
@@ -256,7 +256,7 @@ BELONGS ya.make
Match type : REFERENCE
Links : https://github.com/nexB/scancode-toolkit/tree/develop/src/licensedcode/data/licenses/proprietary-license.LICENSE
Files with this license:
- sqlite3.c [120162:120162]
+ sqlite3.c [120175:120175]
KEEP Public-Domain f14cda0580418473b9b9cbd71db6f933
BELONGS ya.make
diff --git a/contrib/libs/sqlite3/config.h b/contrib/libs/sqlite3/config.h
index ff679d6f17f..f5d600588d6 100644
--- a/contrib/libs/sqlite3/config.h
+++ b/contrib/libs/sqlite3/config.h
@@ -114,13 +114,13 @@
#define PACKAGE_NAME "sqlite"
/* Define to the full name and version of this package. */
-#define PACKAGE_STRING "sqlite 3.38.1"
+#define PACKAGE_STRING "sqlite 3.38.2"
/* Define to the one symbol short name of this package. */
#define PACKAGE_TARNAME "sqlite"
/* Define to the version of this package. */
-#define PACKAGE_VERSION "3.38.1"
+#define PACKAGE_VERSION "3.38.2"
/* Define to 1 if you have the ANSI C header files. */
#define STDC_HEADERS 1
diff --git a/contrib/libs/sqlite3/sqlite3.c b/contrib/libs/sqlite3/sqlite3.c
index e8f8a37fd25..751dc8e33fc 100644
--- a/contrib/libs/sqlite3/sqlite3.c
+++ b/contrib/libs/sqlite3/sqlite3.c
@@ -1,6 +1,6 @@
/******************************************************************************
** This file is an amalgamation of many separate C source files from SQLite
-** version 3.38.1. By combining all the individual C code files into this
+** version 3.38.2. By combining all the individual C code files into this
** single large file, the entire code can be compiled as a single translation
** unit. This allows many compilers to do optimizations that would not be
** possible if the files were compiled separately. Performance improvements
@@ -453,9 +453,9 @@ extern "C" {
** [sqlite3_libversion_number()], [sqlite3_sourceid()],
** [sqlite_version()] and [sqlite_source_id()].
*/
-#define SQLITE_VERSION "3.38.1"
-#define SQLITE_VERSION_NUMBER 3038001
-#define SQLITE_SOURCE_ID "2022-03-12 13:37:29 38c210fdd258658321c85ec9c01a072fda3ada94540e3239d29b34dc547aalt1"
+#define SQLITE_VERSION "3.38.2"
+#define SQLITE_VERSION_NUMBER 3038002
+#define SQLITE_SOURCE_ID "2022-03-26 13:51:10 d33c709cc0af66bc5b6dc6216eba9f1f0b40960b9ae83694c986fbf4c1d6alt1"
/*
** CAPI3REF: Run-Time Library Version Numbers
@@ -39693,11 +39693,17 @@ static int unixShmLock(
int flags /* What to do with the lock */
){
unixFile *pDbFd = (unixFile*)fd; /* Connection holding shared memory */
- unixShm *p = pDbFd->pShm; /* The shared memory being locked */
- unixShmNode *pShmNode = p->pShmNode; /* The underlying file iNode */
+ unixShm *p; /* The shared memory being locked */
+ unixShmNode *pShmNode; /* The underlying file iNode */
int rc = SQLITE_OK; /* Result code */
u16 mask; /* Mask of locks to take or release */
- int *aLock = pShmNode->aLock;
+ int *aLock;
+
+ p = pDbFd->pShm;
+ if( p==0 ) return SQLITE_IOERR_SHMLOCK;
+ pShmNode = p->pShmNode;
+ if( NEVER(pShmNode==0) ) return SQLITE_IOERR_SHMLOCK;
+ aLock = pShmNode->aLock;
assert( pShmNode==pDbFd->pInode->pShmNode );
assert( pShmNode->pInode==pDbFd->pInode );
@@ -46985,10 +46991,14 @@ static int winShmLock(
winFile *pDbFd = (winFile*)fd; /* Connection holding shared memory */
winShm *p = pDbFd->pShm; /* The shared memory being locked */
winShm *pX; /* For looping over all siblings */
- winShmNode *pShmNode = p->pShmNode;
+ winShmNode *pShmNode;
int rc = SQLITE_OK; /* Result code */
u16 mask; /* Mask of locks to take or release */
+ if( p==0 ) return SQLITE_IOERR_SHMLOCK;
+ pShmNode = p->pShmNode;
+ if( NEVER(pShmNode==0) ) return SQLITE_IOERR_SHMLOCK;
+
assert( ofst>=0 && ofst+n<=SQLITE_SHM_NLOCK );
assert( n>=1 );
assert( flags==(SQLITE_SHM_LOCK | SQLITE_SHM_SHARED)
@@ -74995,24 +75005,6 @@ SQLITE_PRIVATE int sqlite3BtreeInsert(
assert( (flags & (BTREE_SAVEPOSITION|BTREE_APPEND|BTREE_PREFORMAT))==flags );
assert( (flags & BTREE_PREFORMAT)==0 || seekResult || pCur->pKeyInfo==0 );
- if( pCur->eState==CURSOR_FAULT ){
- assert( pCur->skipNext!=SQLITE_OK );
- return pCur->skipNext;
- }
-
- assert( cursorOwnsBtShared(pCur) );
- assert( (pCur->curFlags & BTCF_WriteFlag)!=0
- && pBt->inTransaction==TRANS_WRITE
- && (pBt->btsFlags & BTS_READ_ONLY)==0 );
- assert( hasSharedCacheTableLock(p, pCur->pgnoRoot, pCur->pKeyInfo!=0, 2) );
-
- /* Assert that the caller has been consistent. If this cursor was opened
- ** expecting an index b-tree, then the caller should be inserting blob
- ** keys with no associated data. If the cursor was opened expecting an
- ** intkey table, the caller should be inserting integer keys with a
- ** blob of associated data. */
- assert( (flags & BTREE_PREFORMAT) || (pX->pKey==0)==(pCur->pKeyInfo==0) );
-
/* Save the positions of any other cursors open on this table.
**
** In some cases, the call to btreeMoveto() below is a no-op. For
@@ -75037,6 +75029,24 @@ SQLITE_PRIVATE int sqlite3BtreeInsert(
}
}
+ if( pCur->eState>=CURSOR_REQUIRESEEK ){
+ rc = moveToRoot(pCur);
+ if( rc && rc!=SQLITE_EMPTY ) return rc;
+ }
+
+ assert( cursorOwnsBtShared(pCur) );
+ assert( (pCur->curFlags & BTCF_WriteFlag)!=0
+ && pBt->inTransaction==TRANS_WRITE
+ && (pBt->btsFlags & BTS_READ_ONLY)==0 );
+ assert( hasSharedCacheTableLock(p, pCur->pgnoRoot, pCur->pKeyInfo!=0, 2) );
+
+ /* Assert that the caller has been consistent. If this cursor was opened
+ ** expecting an index b-tree, then the caller should be inserting blob
+ ** keys with no associated data. If the cursor was opened expecting an
+ ** intkey table, the caller should be inserting integer keys with a
+ ** blob of associated data. */
+ assert( (flags & BTREE_PREFORMAT) || (pX->pKey==0)==(pCur->pKeyInfo==0) );
+
if( pCur->pKeyInfo==0 ){
assert( pX->pKey==0 );
/* If this is an insert into a table b-tree, invalidate any incrblob
@@ -75125,8 +75135,7 @@ SQLITE_PRIVATE int sqlite3BtreeInsert(
}
}
assert( pCur->eState==CURSOR_VALID
- || (pCur->eState==CURSOR_INVALID && loc)
- || CORRUPT_DB );
+ || (pCur->eState==CURSOR_INVALID && loc) );
pPage = pCur->pPage;
assert( pPage->intKey || pX->nKey>=0 || (flags & BTREE_PREFORMAT) );
@@ -75413,12 +75422,16 @@ SQLITE_PRIVATE int sqlite3BtreeDelete(BtCursor *pCur, u8 flags){
assert( hasSharedCacheTableLock(p, pCur->pgnoRoot, pCur->pKeyInfo!=0, 2) );
assert( !hasReadConflicts(p, pCur->pgnoRoot) );
assert( (flags & ~(BTREE_SAVEPOSITION | BTREE_AUXDELETE))==0 );
- if( pCur->eState==CURSOR_REQUIRESEEK ){
- rc = btreeRestoreCursorPosition(pCur);
- assert( rc!=SQLITE_OK || CORRUPT_DB || pCur->eState==CURSOR_VALID );
- if( rc || pCur->eState!=CURSOR_VALID ) return rc;
+ if( pCur->eState!=CURSOR_VALID ){
+ if( pCur->eState>=CURSOR_REQUIRESEEK ){
+ rc = btreeRestoreCursorPosition(pCur);
+ assert( rc!=SQLITE_OK || CORRUPT_DB || pCur->eState==CURSOR_VALID );
+ if( rc || pCur->eState!=CURSOR_VALID ) return rc;
+ }else{
+ return SQLITE_CORRUPT_BKPT;
+ }
}
- assert( CORRUPT_DB || pCur->eState==CURSOR_VALID );
+ assert( pCur->eState==CURSOR_VALID );
iCellDepth = pCur->iPage;
iCellIdx = pCur->ix;
@@ -125100,7 +125113,7 @@ SQLITE_PRIVATE void sqlite3TableAffinity(Vdbe *v, Table *pTab, int iReg){
}
for(i=j=0; i<pTab->nCol; i++){
- assert( pTab->aCol[i].affinity!=0 );
+ assert( pTab->aCol[i].affinity!=0 || sqlite3VdbeParser(v)->nErr>0 );
if( (pTab->aCol[i].colFlags & COLFLAG_VIRTUAL)==0 ){
zColAff[j++] = pTab->aCol[i].affinity;
}
@@ -133541,7 +133554,7 @@ SQLITE_PRIVATE int sqlite3InitOne(sqlite3 *db, int iDb, char **pzErrMsg, u32 mFl
sqlite3ResetAllSchemasOfConnection(db);
pDb = &db->aDb[iDb];
}else
- if( rc==SQLITE_OK || (db->flags&SQLITE_NoSchemaError)){
+ if( rc==SQLITE_OK || ((db->flags&SQLITE_NoSchemaError) && rc!=SQLITE_NOMEM)){
/* Hack: If the SQLITE_NoSchemaError flag is set, then consider
** the schema loaded, even if errors (other than OOM) occurred. In
** this situation the current sqlite3_prepare() operation will fail,
@@ -146287,6 +146300,7 @@ SQLITE_API int sqlite3_declare_vtab(sqlite3 *db, const char *zCreateTable){
sqlite3ParseObjectInit(&sParse, db);
sParse.eParseMode = PARSE_MODE_DECLARE_VTAB;
+ sParse.disableTriggers = 1;
/* We should never be able to reach this point while loading the
** schema. Nevertheless, defend against that (turn off db->init.busy)
** in case a bug arises. */
@@ -154584,8 +154598,17 @@ static void whereLoopOutputAdjust(
/* If there are extra terms in the WHERE clause not used by an index
** that depend only on the table being scanned, and that will tend to
** cause many rows to be omitted, then mark that table as
- ** "self-culling". */
- pLoop->wsFlags |= WHERE_SELFCULL;
+ ** "self-culling".
+ **
+ ** 2022-03-24: Self-culling only applies if either the extra terms
+ ** are straight comparison operators that are non-true with NULL
+ ** operand, or if the loop is not a LEFT JOIN.
+ */
+ if( (pTerm->eOperator & 0x3f)!=0
+ || (pWC->pWInfo->pTabList->a[pLoop->iTab].fg.jointype & JT_LEFT)==0
+ ){
+ pLoop->wsFlags |= WHERE_SELFCULL;
+ }
}
if( pTerm->truthProb<=0 ){
/* If a truth probability is specified using the likelihood() hints,
@@ -157884,6 +157907,26 @@ whereBeginError:
}
#endif
+#ifdef SQLITE_DEBUG
+/*
+** Return true if cursor iCur is opened by instruction k of the
+** bytecode. Used inside of assert() only.
+*/
+static int cursorIsOpen(Vdbe *v, int iCur, int k){
+ while( k>=0 ){
+ VdbeOp *pOp = sqlite3VdbeGetOp(v,k--);
+ if( pOp->p1!=iCur ) continue;
+ if( pOp->opcode==OP_Close ) return 0;
+ if( pOp->opcode==OP_OpenRead ) return 1;
+ if( pOp->opcode==OP_OpenWrite ) return 1;
+ if( pOp->opcode==OP_OpenDup ) return 1;
+ if( pOp->opcode==OP_OpenAutoindex ) return 1;
+ if( pOp->opcode==OP_OpenEphemeral ) return 1;
+ }
+ return 0;
+}
+#endif /* SQLITE_DEBUG */
+
/*
** Generate the end of the WHERE loop. See comments on
** sqlite3WhereBegin() for additional information.
@@ -158136,14 +158179,15 @@ SQLITE_PRIVATE void sqlite3WhereEnd(WhereInfo *pWInfo){
){
int x = pOp->p2;
assert( pIdx->pTable==pTab );
+#ifdef SQLITE_ENABLE_OFFSET_SQL_FUNC
+ if( pOp->opcode==OP_Offset ){
+ /* Do not need to translate the column number */
+ }else
+#endif
if( !HasRowid(pTab) ){
Index *pPk = sqlite3PrimaryKeyIndex(pTab);
x = pPk->aiColumn[x];
assert( x>=0 );
-#ifdef SQLITE_ENABLE_OFFSET_SQL_FUNC
- }else if( pOp->opcode==OP_Offset ){
- /* Do not need to translate the column number */
-#endif
}else{
testcase( x!=sqlite3StorageColumnToTable(pTab,x) );
x = sqlite3StorageColumnToTable(pTab,x);
@@ -158153,9 +158197,22 @@ SQLITE_PRIVATE void sqlite3WhereEnd(WhereInfo *pWInfo){
pOp->p2 = x;
pOp->p1 = pLevel->iIdxCur;
OpcodeRewriteTrace(db, k, pOp);
+ }else{
+ /* Unable to translate the table reference into an index
+ ** reference. Verify that this is harmless - that the
+ ** table being referenced really is open.
+ */
+#ifdef SQLITE_ENABLE_OFFSET_SQL_FUNC
+ assert( (pLoop->wsFlags & WHERE_IDX_ONLY)==0
+ || cursorIsOpen(v,pOp->p1,k)
+ || pOp->opcode==OP_Offset
+ );
+#else
+ assert( (pLoop->wsFlags & WHERE_IDX_ONLY)==0
+ || cursorIsOpen(v,pOp->p1,k)
+ );
+#endif
}
- assert( (pLoop->wsFlags & WHERE_IDX_ONLY)==0 || x>=0
- || pWInfo->eOnePass );
}else if( pOp->opcode==OP_Rowid ){
pOp->p1 = pLevel->iIdxCur;
pOp->opcode = OP_IdxRowid;
@@ -234394,7 +234451,7 @@ static void fts5SourceIdFunc(
){
assert( nArg==0 );
UNUSED_PARAM2(nArg, apUnused);
- sqlite3_result_text(pCtx, "fts5: 2022-03-12 13:37:29 38c210fdd258658321c85ec9c01a072fda3ada94540e3239d29b34dc547a8cbc", -1, SQLITE_TRANSIENT);
+ sqlite3_result_text(pCtx, "fts5: 2022-03-26 13:51:10 d33c709cc0af66bc5b6dc6216eba9f1f0b40960b9ae83694c986fbf4c1d6f08f", -1, SQLITE_TRANSIENT);
}
/*
diff --git a/contrib/libs/sqlite3/sqlite3.h b/contrib/libs/sqlite3/sqlite3.h
index 4f731b7af26..8e45e939d2d 100644
--- a/contrib/libs/sqlite3/sqlite3.h
+++ b/contrib/libs/sqlite3/sqlite3.h
@@ -146,9 +146,9 @@ extern "C" {
** [sqlite3_libversion_number()], [sqlite3_sourceid()],
** [sqlite_version()] and [sqlite_source_id()].
*/
-#define SQLITE_VERSION "3.38.1"
-#define SQLITE_VERSION_NUMBER 3038001
-#define SQLITE_SOURCE_ID "2022-03-12 13:37:29 38c210fdd258658321c85ec9c01a072fda3ada94540e3239d29b34dc547aalt1"
+#define SQLITE_VERSION "3.38.2"
+#define SQLITE_VERSION_NUMBER 3038002
+#define SQLITE_SOURCE_ID "2022-03-26 13:51:10 d33c709cc0af66bc5b6dc6216eba9f1f0b40960b9ae83694c986fbf4c1d6alt1"
/*
** CAPI3REF: Run-Time Library Version Numbers