diff options
Diffstat (limited to 'src/where.c')
-rw-r--r-- | src/where.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/src/where.c b/src/where.c index 3c0244e68..f962d6f35 100644 --- a/src/where.c +++ b/src/where.c @@ -4896,7 +4896,8 @@ WhereInfo *sqlite3WhereBegin( WHERETRACE(("*** Optimizer selects table %d for loop %d" " with cost=%g and nRow=%g\n", bestJ, pLevel-pWInfo->a, bestPlan.rCost, bestPlan.plan.nRow)); - if( (bestPlan.plan.wsFlags & WHERE_ORDERBY)!=0 ){ + /* The ALWAYS() that follows was added to hush up clang scan-build */ + if( (bestPlan.plan.wsFlags & WHERE_ORDERBY)!=0 && ALWAYS(ppOrderBy) ){ *ppOrderBy = 0; } if( (bestPlan.plan.wsFlags & WHERE_DISTINCT)!=0 ){ |