aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authordrh <drh@noemail.net>2008-07-08 19:45:02 +0000
committerdrh <drh@noemail.net>2008-07-08 19:45:02 +0000
commitc8c0f8fc858d6247c9b7bcc52fd2417ceebde85e (patch)
tree484726bd05364b41a0a9ee271714084c69c25629 /src
parentf089aa459e97f6f8ed27efdc958e8ee642b0b4bb (diff)
downloadsqlite-c8c0f8fc858d6247c9b7bcc52fd2417ceebde85e.tar.gz
sqlite-c8c0f8fc858d6247c9b7bcc52fd2417ceebde85e.zip
Fix a bug in where.c introduced by check-in (5373). (CVS 5375)
FossilOrigin-Name: 1ed98f9e617fb422efc37c4a3a5c5f0702467868
Diffstat (limited to 'src')
-rw-r--r--src/where.c5
1 files changed, 2 insertions, 3 deletions
diff --git a/src/where.c b/src/where.c
index 97edf5be7..069b70778 100644
--- a/src/where.c
+++ b/src/where.c
@@ -16,7 +16,7 @@
** so is applicable. Because this module is responsible for selecting
** indices, you might also think of this module as the "query optimizer".
**
-** $Id: where.c,v 1.312 2008/07/08 18:05:26 drh Exp $
+** $Id: where.c,v 1.313 2008/07/08 19:45:02 drh Exp $
*/
#include "sqliteInt.h"
@@ -2157,8 +2157,7 @@ WhereInfo *sqlite3WhereBegin(
ppIdxInfo);
flags = WHERE_VIRTUALTABLE;
pIndex = *ppIdxInfo;
- assert( pIndex!=0 );
- if( pIndex->orderByConsumed ){
+ if( pIndex && pIndex->orderByConsumed ){
flags = WHERE_VIRTUALTABLE | WHERE_ORDERBY;
}
pIdx = 0;