1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-07-22 00:02:13 +03:00
Commit Graph

9788 Commits

Author SHA1 Message Date
da5f813878 Approximately 100 typo corrections spanning the whole tree, submitted via [forum:0db9827f0464bc33|forum post 0db9827f0464bc33] and individually audited and verified. Affects only code comments, innocuous test strings, error message text in tool (not library) code, and configure-level help text.
FossilOrigin-Name: f50c21484d3cac73589da0376c423de39ae8b842218105786c5aa3726e4dcaed
2025-02-27 21:17:55 +00:00
3398441bfc Reimplement testrunner_data.tcl::trd_get_bin_name() to assume a .exe extension on all platforms not matching "unix", to avoid having to do file-exists checks.
FossilOrigin-Name: ce5519102a1b4df5d513835974799cdcda3478ec53ae99bbb631951095291919
2025-02-27 19:40:02 +00:00
drh
29820d39d8 Fix build break in [e2bd23f251359e7a].
FossilOrigin-Name: 6ed84211033ee0ff00c8fd088979fe06d3a264e4f935162f36a62c00af135c63
2025-02-27 15:52:15 +00:00
e1e822ca23 Teach testrunner how to run local binaries which have a .exe extension. Also teach it to recognized mingw environments (but actually building the test programs there currently doesn't work).
FossilOrigin-Name: e2bd23f251359e7a818c4cfacf114aa9fd8c0a9a1cb802654e96fad67b505508
2025-02-26 19:22:52 +00:00
94c42564f3 Test testrunner.tcl to identify an msys environment.
FossilOrigin-Name: e9f777ceda9fca51c37caca0afeadfc3f99b86e945496f52c71adcc520dcee98
2025-02-26 18:31:42 +00:00
drh
b5f74ee637 Disable some misuse tests that sometimes cause segfaults during
"make releasetest".

FossilOrigin-Name: 5856251a7e8a69aa181f89533bc2a78812d8b450a407b4b2f73f0c146cd78072
2025-02-25 21:16:13 +00:00
5d60f47001 Approximately 50 typo fixes, spanning the whole tree, contributed via [forum:006c8fa165083ac3|forum post 006c8fa165083ac3] and individually checked for correctness. Affects only code comments, docs, and a single line of debug output in a test app.
FossilOrigin-Name: af928818a030924060ee0762431dae0f16d53a62f4e1132754d052eb9c621ac2
2025-02-25 20:55:14 +00:00
drh
b8ec04ee02 Fix a test case that was broken when the default --escape type was changed
by the previous check-in.

FossilOrigin-Name: 5f2531e068b4856db2270518c370b65cbd0c0ab5443d76f1fb1116fe9ad80296
2025-02-25 20:36:46 +00:00
drh
846643ebad Change the default control-character escape algorithm from "symbol" to
"ascii", since the "ascii" algorithm works even on terminals that do
not support unicode.

FossilOrigin-Name: d35320495eb282601ab4f3b9efc53c7c1d58e890f025317e34c7046a43c8cb53
2025-02-25 20:10:46 +00:00
drh
87ad172c50 Enhancements to help avoid problems in the CLI when trying display content
that contains ANSI escape codes:  (1) Add the --escape MODE option to the CLI
where MODE is one of "symbol", "ascii", "off" where the default is "symbol".
(2) Add the unistr() SQL function.  (3) Add the unistr_quote() SQL function.
(4) Add the %#Q and %#q conversions in the built-in printf.

FossilOrigin-Name: e3e509ae145ee2623ac68ededa59991a97fcd28313e03f67a3890b560c5381b0
2025-02-25 15:57:49 +00:00
dan
18d9b12e90 Fix a test script problem causing errors with Tcl 9.
FossilOrigin-Name: dbec2c47d09027f2458036f675c8af3f8f152c0530799582eeac231649eba501
2025-02-25 13:33:43 +00:00
dan
fb8c46510e Avoid running certain tests in walsetlk2.test if SQLITE_ENABLE_SETLK_TIMEOUT is set to 2, not 1.
FossilOrigin-Name: 86788c08fa09019f224d5dbd76f06c1d113b04ca5eca5d773719194a8b02da22
2025-02-25 11:48:57 +00:00
drh
c46fbec350 Fix the new shellA.test test script so that it works with Valgrind.
FossilOrigin-Name: c3949852cee320c2e02123b99c33155c459b10b2ac8e4fe80b1b7624c9ce0817
2025-02-24 23:34:50 +00:00
drh
e4f7af1908 Only use unistr() in columnar formats when strictly needed.
Do not use unistr() in insert mode when --escape is off.
More test cases.

FossilOrigin-Name: e029828de91b10b4c7f4a19bc70c35e4f36fae4ebf32b40553a6ba9f2b3af295
2025-02-24 17:50:49 +00:00
drh
7db5e50b8d Bug fix and initial test-case infrastructure for control-character escaping
in the CLI.

FossilOrigin-Name: c809997792602a7299b8ab84d018a03d291695e308ce750fc8b9d7a824edfd6e
2025-02-24 13:27:16 +00:00
dan
b081a391ce Merge latest changes from trunk into this branch.
FossilOrigin-Name: 55324d1c862c42b95251a398c40930d9fa94debb1aec7d3d0ae734d6b17b4a59
2025-02-24 10:52:34 +00:00
drh
96a65cc474 Three different --escape modes: symbol, ascii, off.
FossilOrigin-Name: b5adb52fc0dc1838cb9c66cff422f2b8ec147e546cf909dd3c48731fa1edfe50
2025-02-24 00:18:12 +00:00
drh
8d15d7ed68 Work toward VT100-safe output from the CLI by default.
FossilOrigin-Name: 44c44620e8648a4265053f194e32b3a5c65d25b4f1fff61ef9b944e7cb0ed624
2025-02-23 20:20:56 +00:00
drh
cc803b209f The number of declared columns in an index is limited to SQLITE_LIMIT_COLUMN.
But the actual number of columns in the implementation might need to be
twice as much to account for the primary key at the end.  Ensure that the
code is able to deal with this.  This is a correction to
check-in [d7729dbbf231d57c].

FossilOrigin-Name: 5822feec43be9352fd87bf9968c39c0218e01ab5fe3ba50431ae21cba79e6c89
2025-02-21 20:35:37 +00:00
drh
ce25007db8 Detect when a UNIQUE or PRIMARY KEY on a WITHOUT ROWID table would need
to use more than SQLITE_LIMIT_COLUMN columns and raise an error.
Also include some unrelated compiler warning fixes.

FossilOrigin-Name: d7729dbbf231d57cbcaaa5004d0a9c4957f112dd6520052995b232aa521c0ca3
2025-02-21 17:03:22 +00:00
drh
21212923f2 Add an ORDER BY to a test case for skip-scan to make the output consistent.
FossilOrigin-Name: 9c9c19414ac243ce48a34bf13a08bff54a465e54a0c09ded50508b8d4bdba227
2025-02-17 20:13:20 +00:00
dan
c274e6dda4 Fix problems in test script fkey6.test.
FossilOrigin-Name: 088e476519c2c759ba9387cb18eaad7c042cc37e45e96237d3125ba33ee3633a
2025-02-17 19:44:45 +00:00
drh
f338ab20ef Fix test cases added for [d7b90d92ffbfc61f] so that they also work when
compiling with ICU support.
[forum:/forumpost/2ca8a09a7e|Forum post 2ca8a09a7e]

FossilOrigin-Name: 5964616dc9de9323fddfede0ded29ee135498c8760017ce1158461f596fe6914
2025-02-14 10:28:28 +00:00
dan
5087eacb18 Ensure the counts of "deferred FK violations" and "deferred immediate FK violations" are kept separate when "PRAGMA defer_foreign_keys" is used.
FossilOrigin-Name: c5190b0fd9bd76653fb7bb08e931699e42c88cef8a00352360d091948cda93a2
2025-02-13 14:47:25 +00:00
dan
41f29806a1 Fix test script errors in walsetlk3.test. Tests still don't all pass.
FossilOrigin-Name: 56eb4114f8bf9971960998ae0b79352767657ee19b5bdfec5149906e72ba170f
2025-02-12 08:07:10 +00:00
dan
138951dc2e Merge latest changes from trunk into this branch.
FossilOrigin-Name: e5ec5bb9f4dc3e02db7ab0e49686f47617af75d3f7d4ab23288a1aea4a693e59
2025-02-11 17:10:46 +00:00
dan
2d87894700 Experimental change to allow clients to block when taking a SHARED lock to connect to a wal mode database.
FossilOrigin-Name: d2d6a000fb9bf8097e0ce9979685408d183be3ab785ceeb11ec1f97a81a83e41
2025-02-10 20:46:14 +00:00
drh
6cc36dfb16 Add the --size option to the test/speedtest.tcl script.
FossilOrigin-Name: 6b9007cb30257ca97de74dec1df47f46f238f034083517a51c24334e4bd30663
2025-02-10 19:12:18 +00:00
drh
8f79342f6a Make the "mix1" testset the default for speedtest1.
FossilOrigin-Name: 7a0c3d0e14984dd49a7c1e824b9e50564094ad57c43182bfec7624a55815f961
2025-02-10 16:34:30 +00:00
drh
dadd0b4085 Enhance speedtest1 with a new testset that calls sqlite3_open() and uses the
connection many times.

FossilOrigin-Name: ce307addb0c7cf72e4cca066521df6e15d1220bce303a3796a794a2ae5fa95b3
2025-02-10 16:13:56 +00:00
drh
5b0b8653b6 Add the "star" testset to speedtest1. Include it as part of "mix1".
FossilOrigin-Name: f1345b84eaae5404268df1d0449c409fe5c4a4f9742bd67a75c7333c8c9cd597
2025-02-09 00:54:56 +00:00
drh
038424727b Adjust the test/speedtest.tcl script so that it uses an on-disk database
rather than an in-memory database.

FossilOrigin-Name: e93d7aa1db9bdbf1996c4c168e67284177e384b7acf176d74a0458258faab05c
2025-02-06 17:29:14 +00:00
drh
31615637f3 New dbsqlfuzz case added to fuzzdata8.db.
FossilOrigin-Name: 7ee20cfc237229dbea7116149c0c35883f7b8087b9ccdce6dca16b6da1c6caf8
2025-02-03 21:24:40 +00:00
drh
589796cd89 Fixes and improved documentation to the new --sqlid and --dbid range
options in fuzzcheck.

FossilOrigin-Name: 59e26632449163a36b803cc7027ed99c1f6b675dda6f0b2b12bbe55884923f08
2025-02-03 18:49:06 +00:00
drh
dbe48d3c8d Enhance fuzzcheck so that the --sqlid and --dbid options can specify a
range of tests to be run.

FossilOrigin-Name: cdd0af6f86e49ade1339ad5a3cc444400a9722a9efdf84a30b3ff9428b7ac36d
2025-02-03 18:36:05 +00:00
drh
c2b446f16a Fix for a potential UAF in FTS5.
FossilOrigin-Name: e33f2fedda17b4f3678fc23c438093c256b0c125da5f1ac42ecaf3d604d54b6a
2025-02-03 18:05:54 +00:00
drh
c6281e4893 New test case for test/fuzzdata8.db
FossilOrigin-Name: 8a882f976e22100b91c7ca4119123f16ad5f03311f0a6dc17449bcdcff29618c
2025-02-03 17:45:41 +00:00
drh
f306ca5286 Add a header comment to test/speedtest1.c that outlines how to compile the
program using historical amalgamation sources, for comparison testing.

FossilOrigin-Name: 602d4dd69ec9a724c69cb41ab15376ec731bfd4894fac0a2b25076b857786c6d
2025-02-02 18:01:32 +00:00
drh
c229f11817 Update to the "--help" output from speedtest1.
FossilOrigin-Name: 5216452047eecdd6c0f6ab85b304f975ed05a394a4ad9ae793fb65d645502b12
2025-02-02 16:52:21 +00:00
drh
5c72a39cfb Enable SQLITE_ENABLE_NORMALIZE for several test configurations.
FossilOrigin-Name: b07c64077a3912ef7cdf23e9411df6387f38baa32f5a11fffec5ba4f93935e27
2025-02-01 21:06:49 +00:00
drh
45b2669ad3 Fix test case numbering in tests recently added to like3.test.
FossilOrigin-Name: 6df2098c548b58c2910837726b666a628d5c712c560c0221a771e8181f71fae7
2025-01-31 18:56:58 +00:00
dan
8fbf400bb0 Remove an assert() that is not true if a trace-callback is deregistered while there are active statements.
FossilOrigin-Name: 0ecfc4d0ebdb272a69f8f98ddb069c7e0735fb899804027eb16f241d83b3d046
2025-01-31 18:33:37 +00:00
dan
f6ca35d88c Fix a problem with LIKE and GLOB processing in utf-16be databases in cases where the utf-8 encoding of a character ends with the byte 0xBF.
FossilOrigin-Name: 4b4f33d791fe4318c4597bee7d2f9e486ed223e731982af470f5cc0dbdc600fc
2025-01-31 14:52:36 +00:00
drh
49906e8e4b The reuse-subroutine optimization [c9a3498113074bbc] might have generated
byte-code that loops forever.  This check-in fixes the problem.

FossilOrigin-Name: 0cc4ed8c6e53aca1f5e94c132bedbc7f561c04a77f1a30b965ffe7560634bfeb
2025-01-30 21:12:58 +00:00
dan
df54ecb1bf Fix a problem causing the write-lock to be held when it should not be in some circumstances following a SEH exception.
FossilOrigin-Name: 7eb5accb7cf937fc967dcd86da0af813fb18a2697348bd231fbefd3c09b930ab
2025-01-30 17:04:28 +00:00
dan
462888819e Have sqlite3_enable_setlk(-1) configure indefinite blocking locks where they are supported.
FossilOrigin-Name: 62009565d2f2a2c4d347e1da0d5b4ad43056742df47fd6ddb92e62f53a2b57f1
2025-01-30 15:26:16 +00:00
drh
1392ff5533 Disable a test case that (intentionally) does use-after-free, as it does
occasionally cause problems even for non-sanitizer builds.

FossilOrigin-Name: 23c7d5bea351c04785153ddb30e19c1236db9d11054ab8229893531026b53655
2025-01-30 12:01:24 +00:00
drh
b0c8b08874 Fix typo in speedtest.md.
FossilOrigin-Name: 984a9cc22c7c8492bf4fae482749663899b0e33a25c32e6ae5c5e98fc12bb83e
2025-01-28 10:56:22 +00:00
dan
43aad25b1b Add the sqlite3_setlk_timeout() API. For setting the timeout used by SQLITE_ENABLE_SETLK_TIMEOUT blocking locks without also setting the regular retry-based busy-timeout.
FossilOrigin-Name: 4a7eb492797abb47b18b7dfc557aeae43a0dea5b861efc203398d5059b10d131
2025-01-27 11:50:03 +00:00
drh
fe54b7a1f4 Small size and complexity reduction on the star-query heuristic. Improved
comments for the star-query heuristic.

FossilOrigin-Name: a7ecb2f4b7eee78b88f1b2e026dffed2007ca4ffeb152632624ab2582839b250
2025-01-26 17:29:33 +00:00