1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-11-18 10:21:03 +03:00

Fix a crash. Not all tests pass, but tests do at least run to completion now.

FossilOrigin-Name: b5d38e28c62dbc4f5f0e1b2590c9d6c2de9a140cc3528cae1968fd741e337fb0
This commit is contained in:
drh
2020-07-14 02:03:35 +00:00
parent 6e4b140e94
commit 751a44ed24
3 changed files with 9 additions and 8 deletions

View File

@@ -4427,7 +4427,8 @@ static int wherePathSolver(WhereInfo *pWInfo, LogEst nRowEst){
}
}
}
}else if( pWInfo->nOBSat==1
}else if( nLoop
&& pWInfo->nOBSat==1
&& (pWInfo->wctrlFlags & (WHERE_ORDERBY_MIN|WHERE_ORDERBY_MAX))!=0
){
pFrom->aLoop[nLoop-1]->wsFlags |= WHERE_ONEROW;