mirror of
https://github.com/sqlite/sqlite.git
synced 2025-11-12 13:01:09 +03:00
Fix a segfault that could occur if a query that used a vector comparison contained certain types of syntax errors.
FossilOrigin-Name: 203f07c5e140e74cf91d0c1e20135c21236f0fc1
This commit is contained in:
@@ -462,8 +462,8 @@ static int exprVectorRegister(
|
||||
int *pRegFree /* OUT: Temp register to free */
|
||||
){
|
||||
assert( pVector->op==TK_VECTOR || pVector->op==TK_SELECT );
|
||||
assert( (pVector->op==TK_VECTOR)==(regSelect==0) );
|
||||
if( regSelect ){
|
||||
assert( pParse->nErr || (pVector->op==TK_VECTOR)==(regSelect==0) );
|
||||
if( pVector->op==TK_SELECT ){
|
||||
*ppExpr = pVector->x.pSelect->pEList->a[iField].pExpr;
|
||||
return regSelect+iField;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user