From: shess Date: Thu, 19 Apr 2007 18:36:32 +0000 (+0000) Subject: Fix bug in fts2 handling of OR queries. When one doclist ends before X-Git-Tag: version-3.6.10~2308 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=3b2f10cd8f41c837b237ee74b8b4f4147d9ef627;p=thirdparty%2Fsqlite.git Fix bug in fts2 handling of OR queries. When one doclist ends before the other, the code potentially tries to read past the end of the doclist. http://www.sqlite.org/cvstrac/tktview?tn=2309 (CVS 3862) FossilOrigin-Name: dfac6082e8ffc52a85c4906107a7fc0e1aa9df82 --- diff --git a/ext/fts2/fts2.c b/ext/fts2/fts2.c index e734d32f81..3c14e8f8bc 100644 --- a/ext/fts2/fts2.c +++ b/ext/fts2/fts2.c @@ -1374,10 +1374,16 @@ static void docListOrMerge( dlwInit(&writer, DL_DOCIDS, pOut); while( !dlrAtEnd(&left) || !dlrAtEnd(&right) ){ - if( dlrAtEnd(&right) || dlrDocid(&left)