]> git.ipfire.org Git - thirdparty/sqlite.git/commitdiff
Fix another instance of an incorrect value for KeyInfo.nXField on a
authordrh <drh@noemail.net>
Tue, 20 Jan 2015 02:50:34 +0000 (02:50 +0000)
committerdrh <drh@noemail.net>
Tue, 20 Jan 2015 02:50:34 +0000 (02:50 +0000)
sorting index.

FossilOrigin-Name: dc711db44ec424a7850231a39088229c23238f1b

manifest
manifest.uuid
src/select.c

index f457526ed0007f0198d60da52930aa815da648db..2740e3bd8c41a0dce88716170a062c337b0bd65e 100644 (file)
--- a/manifest
+++ b/manifest
@@ -1,5 +1,5 @@
-C Ensure\sthat\sthe\sKeyInfo.nXField\svalue\sfor\sephemeral\stables\sused\sto\simplement\nORDER\sBY\sor\sGROUP\sBY\sclauses\sis\sset\scorrectly,\sso\sthat\sthe\nsqlite3VdbeFindCompare()\sroutine\scan\schoose\sthe\scorrect\scomparison\sfunction.\nAdd\sassert()\sstatements\sto\sthe\shigh-speed\scomparison\sfunctions\sto\sdetect\ncases\swhere\sthey\sare\sinappropriately\schosen.\nFix\sfor\sticket\s[f97c4637102a3ae72b7911].
-D 2015-01-19T21:38:53.373
+C Fix\sanother\sinstance\sof\san\sincorrect\svalue\sfor\sKeyInfo.nXField\son\sa\nsorting\sindex.
+D 2015-01-20T02:50:34.333
 F Makefile.arm-wince-mingw32ce-gcc d6df77f1f48d690bd73162294bbba7f59507c72f
 F Makefile.in 5407a688f4d77a05c18a8142be8ae5a2829dd610
 F Makefile.linux-gcc 91d710bdc4998cb015f39edf3cb314ec4f4d7e23
@@ -229,7 +229,7 @@ F src/printf.c ea82bcb1b83273b4c67177c233c1f78c81fc42f9
 F src/random.c ba2679f80ec82c4190062d756f22d0c358180696
 F src/resolve.c f6c46d3434439ab2084618d603e6d6dbeb0d6ada
 F src/rowset.c eccf6af6d620aaa4579bd3b72c1b6395d9e9fa1e
-F src/select.c bc02e8b084891af5a3b428faa9cf367aff887d1a
+F src/select.c a4e8fda24c8eab2682a058bdda0d5d68cfe3919c
 F src/shell.c 5b8e786a7c8eec87fa3f2ea615b337d2d99e284c
 F src/sqlite.h.in 9dfc99d6533d36d6a549c4f3f01cacc8be956ada
 F src/sqlite3.rc 992c9f5fb8285ae285d6be28240a7e8d3a7f2bad
@@ -1237,11 +1237,7 @@ F tool/vdbe_profile.tcl 67746953071a9f8f2f668b73fe899074e2c6d8c1
 F tool/warnings-clang.sh f6aa929dc20ef1f856af04a730772f59283631d4
 F tool/warnings.sh 0abfd78ceb09b7f7c27c688c8e3fe93268a13b32
 F tool/win/sqlite.vsix deb315d026cc8400325c5863eef847784a219a2f
-P 7d68a42face3ab14ed88407d4331872f5b243fdf
-Q +f7201bb0cdc9e1425c68599b32434de2231dca36
-R e444e9c867dd5196e8f0c39e1d05468d
-T *branch * branch-3.8.8
-T *sym-branch-3.8.8 *
-T -sym-trunk *
+P 59e592f67fb88e2630c04655058fc63439af0913
+R a75344ea7d1777cafe291b25f483be1b
 U drh
-Z c6d384008cf12ca28742ca7fe4d481ac
+Z 819cac8cb689cc8d7863cd16be4845af
index d437c568f0122a94ccc51b9890ce6e44344300be..0238e1a8a6b53d374f47db804099b4dd7554ddf7 100644 (file)
@@ -1 +1 @@
-59e592f67fb88e2630c04655058fc63439af0913
\ No newline at end of file
+dc711db44ec424a7850231a39088229c23238f1b
\ No newline at end of file
index 403732646736262f0f70af2e3278ed7cc7871a08..39a0550f2aea2a9e290ed30422b04054ee69864a 100644 (file)
@@ -543,7 +543,9 @@ static void pushOntoSorter(
     pKI = pOp->p4.pKeyInfo;
     memset(pKI->aSortOrder, 0, pKI->nField); /* Makes OP_Jump below testable */
     sqlite3VdbeChangeP4(v, -1, (char*)pKI, P4_KEYINFO);
-    pOp->p4.pKeyInfo = keyInfoFromExprList(pParse, pSort->pOrderBy, nOBSat, 1);
+    testcase( pKI->nXField>2 );
+    pOp->p4.pKeyInfo = keyInfoFromExprList(pParse, pSort->pOrderBy, nOBSat,
+                                           pKI->nXField-1);
     addrJmp = sqlite3VdbeCurrentAddr(v);
     sqlite3VdbeAddOp3(v, OP_Jump, addrJmp+1, 0, addrJmp+1); VdbeCoverage(v);
     pSort->labelBkOut = sqlite3VdbeMakeLabel(v);