Commit Graph

21065 Commits

Author SHA1 Message Date
dan
8b4d0e2cba Ensure fts3/4 prefix indexes are flushed to disk before an 'optimize' command. Fix for [745f1abc].
FossilOrigin-Name: 4ed905b18847d4dbf5a2570052abced338065f824137b90300f62d77b3159d80
2019-10-11 15:33:13 +00:00
dan
9613c9f4a6 Fix the fts3/4 integrity-check command so that it works with "ORDER=DESC" tables. Fix for [8a6fa2bb].
FossilOrigin-Name: 5863546df99abd1ad4ebcaba18dec647be4368e2c13ce0b28e48c8608d3e87ef
2019-10-11 14:27:17 +00:00
drh
656d535ae6 Increase the version number to 3.31.0 for the next release cycle.
FossilOrigin-Name: ffd4c30620abe6ba38d82f3db934d18cc8468aaac4cd50a4e01be8910854d3f0
2019-10-11 14:25:00 +00:00
drh
21f6daa2cd Faster response to sqlite3_interrupt() in the OP_IntegrityCk and OP_Count
opcodes.

FossilOrigin-Name: bf875dc59909f9c22f7c1fc843bc4d9e5d97af5cb4ef43c4fa1d566ddfdeaacb
2019-10-11 14:21:48 +00:00
mistachkin
af94adf049 Update the autoconf makefile for MSVC.
FossilOrigin-Name: 9455643eecb74c8ac93ad3b3566f30e380dd912cdce3de993da5af42973ac59c
2019-10-10 23:58:28 +00:00
mistachkin
6dcf9a451e Fix harmless compiler warning seen with MSVC.
FossilOrigin-Name: 73a82114733af2a316f20eb8578badef307d14286c6ec03197744a6793425161
2019-10-10 23:58:16 +00:00
dan
0287c95165 Prevent SQLite from assuming that if ((? IS NOT NULL) IS NOT NULL) is true, ? may not be NULL. Fix for [d51a8696].
FossilOrigin-Name: 7833feecfe745e237f239ee4c38a9e4bf7ad66a32919150208da87c00a826473
2019-10-10 17:09:44 +00:00
dan
cd79010964 Fix a problem in the fts3 integrity-check routine causing it to report as corrupt tables that contain values with embedded 0x00 bytes.
FossilOrigin-Name: 629e20c9880acc2cb9e2fa6da39a15a90483e9a8f433df29d285c23bdfb03b0b
2019-10-10 16:41:44 +00:00
dan
3703edf110 Be sure to rewrite column references inside FILTER clauses and window frame definitions when flattening queries. Fix for [1079ad19].
FossilOrigin-Name: ccba7202b69d239724c3b589439c9c3b0e1bba237accfeb11c39d492522b8719
2019-10-10 15:17:09 +00:00
dan
da03c1e65e Avoid assuming that an expression that contains the sub-expression (? IS FALSE) or (? IS TRUE) may only be true if ? is non-null. Fix for [a976c487].
FossilOrigin-Name: eb7ed90b8a65748f0721aaf7bdddd2207f552be5015603fbfb7044d815ae2f36
2019-10-09 21:14:00 +00:00
dan
ae55737fbf Do not allow users to effectively disable fts5 crisismerge operations by setting the crisismerge threshold to higher than the maximum allowable segment b-trees on a single level. Fix for [d392017c].
FossilOrigin-Name: 86e497209217abb7bcb491a023cd353f3c7c9c103ebd9f58dd8661b12cf3694c
2019-10-09 18:36:32 +00:00
drh
92a2824cc6 An improved fix for the dbsqlfuzz-discovered ALWAYS() failure following OOM in
sqlite3ExprCollSeq().  This time with a test case (engineered by Dan).

FossilOrigin-Name: 907f7965b335d8d5441f2e386bb190d1f93ffcd45ca98d2d1c621dede491fc5e
2019-10-09 15:37:58 +00:00
dan
a6bd1871d1 Disallow fts5 page sizes greater than 65536 bytes - as there are 16-bit offsets used in the page header.
FossilOrigin-Name: 75775c5ab44e497cb19be10397229637f1374f05c3244e8f92d6c54fcea94f5f
2019-10-09 15:26:45 +00:00
drh
76f8318e31 Remove the "fastfuzztest" makefile target. Use only "fuzztest".
FossilOrigin-Name: e17571c789db31123642d0ed1f3d8764e070019e0deb8b88cce58d2183551cdf
2019-10-09 15:08:27 +00:00
drh
9fd04bfd29 New test cases added to test/fuzzdata8.db.
FossilOrigin-Name: b68d21e93a0839b42f49845918df7738ee7fa2a05c7f4ae2f89fdbb5e47ad8eb
2019-10-09 15:03:45 +00:00
drh
efb02281a4 Change sqlite3SelectDup() to always return NULL if an OOM has occurred.
FossilOrigin-Name: 01ba4641ab436c6065c8725908fc0913f2abded4ea62e004b7534e0116b9451a
2019-10-09 15:00:37 +00:00
drh
c0efa4d309 Use the "fuzztest" target in place of "fastfuzztest".
FossilOrigin-Name: 7129e468fd182c1820cdfa2c66a81d1697e5d1580680b77c0df9bb0ae0049e0d
2019-10-09 13:52:31 +00:00
drh
07eb7f89a0 Remove the obsolete "fastfuzztest" target from the makefiles.
FossilOrigin-Name: 3d44f1ee0f606409bc9c091dae2c9d2e78ada318a0de08437f4f4835a1a5d203
2019-10-09 13:12:55 +00:00
drh
f3ce2483f5 Save CPU cycles in sqlite3Prepare() by, among other things, shifting the
EXPLAIN column label logic over to sqlite3VdbeMakeReady().

FossilOrigin-Name: 1ca5ef84506aac3e2f08baa36095b3befdeedf2a3443fcd9154a277b55cbf64b
2019-10-09 01:19:07 +00:00
dan
fbd79cc585 Fix problems with using the fts5 'rebuild' command inside a transaction that contains other updates of the same table. Fix for [e258f008].
FossilOrigin-Name: 238e0835714696aba0631f288fcc30ec5fddb43893d469c6bf017f386b3cddee
2019-10-08 13:34:24 +00:00
dan
b186a622ee Disallow page-sizes smaller than 32 bytes in fts5. Also ensure the fts5 integrity-check works even when "PRAGMA reverse_unordered_selects" is true. Fix for [265e935b26].
FossilOrigin-Name: 8ab0aebdb3c2d6fb3160b2c58ce6cc0495a6ddd960878a6395958c837f3d1b71
2019-10-07 20:36:18 +00:00
drh
38587159dd Omit a pointless memory allocation in vdbeSorterSort().
FossilOrigin-Name: 5d76dbc5b0584c15d7d59e5c079868f2077f32b865f406b40ec837b8ab6ef2e1
2019-10-07 20:33:26 +00:00
dan
03e025e217 Fix a problem with running ALTER TABLE ADD COLUMN statements within a transaction that writes to one or more virtual tables.
FossilOrigin-Name: 31e85fbbc4cfd09a98b4a6dc6624f863816f376c6a4eef1fafc657c8e1abbc36
2019-10-07 18:43:21 +00:00
dan
8451e1fa27 Add a test case for the assert() fix in the previous commit.
FossilOrigin-Name: 32fba11ab72f6300391267eaad64e92fa767c289029e668e4bd6c9165acf1487
2019-10-07 13:46:43 +00:00
drh
093589de5e Fix a faulty assert() statement in the sqlite3VdbeMemExpandBlob() routine.
FossilOrigin-Name: 69a26eade2f92029e722a5a654214b1e2a3fc7ed497ce9aa5a7dce944f90e502
2019-10-07 13:26:58 +00:00
drh
b29ef5ef03 Fix the OP_SeekRowid opcode so that it works correctly with a Real argument
without damaging the value in the register that is the argument.
Ticket [b2d4edaffdc156cc].  Test cases in TH3.

FossilOrigin-Name: 3cde82c86b963fa75192907d548febd3882c7d8fc7daf1903fadd5ca46623be1
2019-10-07 01:05:57 +00:00
drh
705e73344e Omit the check for conflicting shared-cache locks in sqlite3Prepare() if the
database connection uses no shared cache.  We might be able to go back and
remove this code completely, due to the newer Schema.iGeneration logic, but
that will take more analysis.  This check-in gives the speed benefit but not
the reduction in code size.

FossilOrigin-Name: 0b73a09270dfafb27f8d1762b547ef8178c9da66f45e7153ff0b76272dfa92f5
2019-10-05 19:53:21 +00:00
drh
1de92a64cd Optimization to sqlite3VtabUnlockList() for the common case when there
is no work to do.

FossilOrigin-Name: fc8d45086dc2bcb9bce756088e99e63cbeedf9129139fb0e6a48b43c4f502180
2019-10-05 19:24:52 +00:00
drh
a22d2fca33 Call sqlite3Prepare() directly, rather than going through sqlite3_prepare(),
when processing the sqlite_master.sql column for a schema.

FossilOrigin-Name: cc49380ea76a4a05843d3a0bdfb925464dc9d72c33cf5ab5243dd07d161ad038
2019-10-05 18:33:25 +00:00
drh
4d29448114 Reorder two comparisons for a small performance gain in OP_Transaction.
FossilOrigin-Name: d7667f6560318272c8b35b478e29b0ed134105dfd119a2fd53ef0490442c60cc
2019-10-05 15:28:24 +00:00
drh
31f69626df Performance optimization to the lookaside-memory disabling mechanism.
FossilOrigin-Name: 17ce1c49cb0ed6fdd8c7c33431bc2afa217f1092c99b8dd608890a8e7aec7fb1
2019-10-05 14:39:36 +00:00
drh
228a52d973 Version 3.30.0
FossilOrigin-Name: c20a35336432025445f9f7e289d0cc3e4003fb17f45a4ce74c6269c407c6e09f
2019-10-04 15:03:17 +00:00
dan
6117a17323 Avoid running a couple of tests in affinity2.test as part of the valgrind permutations, as the way floating point computations are simulated by valgrind causes them to fail.
FossilOrigin-Name: 7f9a4b6015ac332a04d3e394a6b3210fc95253d8786a261178a5639cb8d9d987
2019-10-03 16:02:22 +00:00
drh
d1c472dab6 Increase the precision of floating point value display in VDBE debugging
output.  No changes to normally deployed code.

FossilOrigin-Name: a561a656ff50efc0103da3988626cea3ef05757403b83960f2aa6c0a48c2765e
2019-10-03 14:51:59 +00:00
dan
b008e4d744 Fix some test script issues that come up with SQLITE_OMIT_VIRTUALTABLE builds.
FossilOrigin-Name: 3934d2d08ee14d644dc01f967c10f219b76b172c963c90a7a8141f2b08a7d5bf
2019-10-03 14:36:36 +00:00
dan
367b8d7aa7 Fix issues with command line invocation of wapptest.tcl.
FossilOrigin-Name: 9e0d5d2640a92070967bc9fdf5c5b1653e41b9c04e04dcb70f18ead10f053aef
2019-10-03 13:44:08 +00:00
drh
9a50f4c72a Update error detection logic in releasetest.tcl to account for new
output formats in USAN.

FossilOrigin-Name: 3f36b988360204628d5ad1df2db34818b9a2d6ba989018d4c17757229f4b0f65
2019-10-02 19:44:42 +00:00
dan
f0578823dd Update corruptM.test to account for the fact that the database schema may be loaded from within the "sqlite3" command for some test permutations.
FossilOrigin-Name: cb9470fc064aad72a4e42c6a021410401b3b1a32446ae8b9cd9c759f0a2a01ef
2019-10-02 19:43:38 +00:00
dan
23d3f5d661 Fix a long-standing problem in fts4 incrmental merge.
FossilOrigin-Name: 67da31e24ebb49c4cac81c9e7cfca37ca422555fd0fdb01d8f180890783c84ff
2019-10-02 19:33:34 +00:00
drh
e2b7a7693e Disable sqlite3_drop_module() tests when virtual tables are omitted from
the build.

FossilOrigin-Name: 9f4035f91a9f914797c67afbf19139b2cd25aea48595f7254fe5d18cd693d972
2019-10-02 00:25:08 +00:00
drh
cfee884e73 Remove references to test scripts analyzeA.test and analyzeB.test from
permutations.test, since those test modules no longer exist.

FossilOrigin-Name: 2394879698107479270c9d899c704de3756ceae177a338b3c37844e2a31aa6dd
2019-10-01 21:31:57 +00:00
drh
5e81e9fdae The nodeReaderInit() function in FTS3 may not assume that the node is
non-empty.

FossilOrigin-Name: 361eb2f682a303bba72b39d322d9de630494ca044fe0508dcb23b6130d312d85
2019-09-30 19:13:31 +00:00
drh
905d4729d3 Add missing comment to constant definitions.
FossilOrigin-Name: 661a3789eb329a2487855e49c31067a9dde4c91c1a3a65b65375d079f906b1da
2019-09-28 18:28:19 +00:00
drh
018dbb17a8 Improvements to a comment. No code changes.
FossilOrigin-Name: 1a3671c7003bfff817a8239424c2f945d9dfced97daadb5a5acab203b9bda69b
2019-09-28 16:14:55 +00:00
drh
5c0666d9e3 In FTS3/4, the poslist end marker must be larger than any other possible
poslist value, even on a corrupt poslist.

FossilOrigin-Name: 752679aea5a6bbde24cbf39e2fa018f7dd1c226d463ca4bd74125303b2255170
2019-09-28 11:19:56 +00:00
drh
5f419b3bba Update requirement marks due to changes in documentation wording.
FossilOrigin-Name: 326cdc16f4db23c1d17596e4ef8d9d7abc672d48665950029ba53fd40c1b2d99
2019-09-27 17:36:37 +00:00
drh
e4079e1fc5 Allow compile-time options -DHAVE_GETHOSTUUID=0 and -DHAVE_GETHOSTUUID=1.
FossilOrigin-Name: 3bcb9cc104e0265a600b03415ad955187fc6445ea8e46dc656412cba5bc1d621
2019-09-27 16:33:27 +00:00
drh
ebc6408484 Alternative implementation of the previous check-in which is testable.
FossilOrigin-Name: 102ef64462cf0d78395ccc7ebb8e3bf6b7647c06b7657a037e051697bc08d6b7
2019-09-27 15:15:38 +00:00
drh
818a3b5486 Fix sqlite3ExprCompare() so that it ignores differences in the Expr.iTable
field for IN operators, as otherwise it can lead to false negatives, which
is usually harmless, but can cause problems for an assert() in the window
function logic.

FossilOrigin-Name: 6a204b192a6c6f21988cab217366f21b14c672b81ceadc43675761a6d8c4484f
2019-09-27 15:01:02 +00:00
dan
7971b7fe92 More minor test file fixes.
FossilOrigin-Name: 352878fe1cbcf7b6803624544bba5a95565d1638d4dd09e91764ddad17889301
2019-09-26 20:57:53 +00:00