]> git.ipfire.org Git - thirdparty/sqlite.git/log
thirdparty/sqlite.git
4 months agoVersion 3.44.4 branch-3.44 patch-release version-3.44.4
drh [Wed, 19 Feb 2025 00:18:53 +0000 (00:18 +0000)] 
Version 3.44.4

FossilOrigin-Name: f1e31fd9961ac82535a5d0702b127d84de8ca21d4df1c51c73e078ea0ad4afa8

4 months agoCherry pick recent fixes into branch-3.44.
drh [Tue, 18 Feb 2025 18:05:16 +0000 (18:05 +0000)] 
Cherry pick recent fixes into branch-3.44.

FossilOrigin-Name: 75bbd094db08d421b7555bda5447902e44adff99cc095e7216a21cb5a3002167

14 months agoMark the BTree cell overflow cache as invalid whenever the rowid goes invalid.
drh [Fri, 12 Apr 2024 15:15:05 +0000 (15:15 +0000)] 
Mark the BTree cell overflow cache as invalid whenever the rowid goes invalid.

FossilOrigin-Name: 0ec6669c84462c9ab965f912d3a09fa56cd99b5491c57da4a1941efa763ed5b0

14 months agoIgnore CHECK constraints when
drh [Tue, 9 Apr 2024 14:08:39 +0000 (14:08 +0000)] 
Ignore CHECK constraints when
qualifying the xfer optimization while running VACUUM.

FossilOrigin-Name: 944d1b6eb346a9b3c32bce3457f8a62013ee5d6b538fa19243036cd2924678d4

15 months agoCheck-in a9657c87c53c1922 is wrong: the IndexedExpr.bMaybeNullRow flag is
drh [Fri, 5 Apr 2024 14:13:43 +0000 (14:13 +0000)] 
Check-in a9657c87c53c1922 is wrong: the IndexedExpr.bMaybeNullRow flag is
required for virtual columns if they are part of an outer join.  Add a
test case to prove it.

FossilOrigin-Name: 083b0f7e771838e5f02744c245e8dbd7bef4fc998df59466ba65c531c7162d99

15 months agoWhen compiling with SQLITE_ALLOW_ROWID_IN_VIEW, if the RETURNING clause of version-3.44.3
drh [Fri, 5 Apr 2024 11:28:30 +0000 (11:28 +0000)] 
When compiling with SQLITE_ALLOW_ROWID_IN_VIEW, if the RETURNING clause of
an UPDATE of a view specifies a rowid, then return NULL for the value of
that rowid.

FossilOrigin-Name: d38cfa6067ccd450c4fac183765c05ff247ecb49ccf172a68ef9d381577df84f

15 months agoFix the xBestIndex method of the pragma virtual table so that it correctly
drh [Sun, 24 Mar 2024 21:15:01 +0000 (21:15 +0000)] 
Fix the xBestIndex method of the pragma virtual table so that it correctly
gives a higher cost to plans where the schema hidden parameter is
unconstrained.

FossilOrigin-Name: d68fb8b5dbb8305e00d2dd14d8fe6b3d9f67e2459102ff160d956a6b75ddc18e

15 months agoDo not automatically assume that ROWID is NOT NULL when compiled with
drh [Sun, 24 Mar 2024 16:42:12 +0000 (16:42 +0000)] 
Do not automatically assume that ROWID is NOT NULL when compiled with
SQLITE_ALLOW_ROWID_IN_VIEW.
dbsqlfuzz 31b38eeb63a4e1562de665078f52b7b47a7543cf

FossilOrigin-Name: b5d2dce18fcd00749a3efe8386df42fca103f86bd862f2610cfb05651ddb9d59

15 months agoFix a assert() that is incorrect, though harmless. Also add a test case.
drh [Thu, 21 Mar 2024 22:08:33 +0000 (22:08 +0000)] 
Fix a assert() that is incorrect, though harmless.  Also add a test case.

FossilOrigin-Name: 57b0c984605d0f437b4930f6b994e15b80340c753d46a679b07d356c645856ea

15 months agoFix test cases for rtree and fts5. No changes to code.
drh [Wed, 20 Mar 2024 16:29:19 +0000 (16:29 +0000)] 
Fix test cases for rtree and fts5.  No changes to code.

FossilOrigin-Name: 633dca907488b721ec1b8e470904af73369c1b1225005038aacb3e8a78c6390c

15 months agoHave rtree avoid keeping a blob handle open following an error.
drh [Wed, 20 Mar 2024 16:04:53 +0000 (16:04 +0000)] 
Have rtree avoid keeping a blob handle open following an error.

FossilOrigin-Name: 1303716a113c51e949acc46fbd01634ce0e5a016cbc2d01bb20dd03ffd1f28e0

15 months agoFollowing a ROLLBACK that reverts changes to an RTREE, any pending queries
drh [Wed, 20 Mar 2024 15:26:30 +0000 (15:26 +0000)] 
Following a ROLLBACK that reverts changes to an RTREE, any pending queries
against that same RTREE abort with code SQLITE_ABORT_ROLLBACK.
dbsqlfuzz de7d17b72d0e842352c998dd86a47b7d0f707be9.

FossilOrigin-Name: b26e5a500ebc358047eff79db61b5edfec319b95fbf8685e6a798c5e6c1923fb

15 months agoBack port various minor patches
drh [Wed, 20 Mar 2024 12:19:40 +0000 (12:19 +0000)] 
Back port various minor patches

FossilOrigin-Name: a1a5c427c2c5cfff1ffeb71b29c9f64121465334c6a3fde8213df1dc2a1228d4

15 months agoAutomatically disable the DISTINCT optimization during query planning if the
drh [Wed, 20 Mar 2024 11:36:26 +0000 (11:36 +0000)] 
Automatically disable the DISTINCT optimization during query planning if the
ORDER BY clause exceeds 63 terms.
dbsqlfuzz afd1d61fc27d14938a0d78a50970fa1e9fbfee58.

FossilOrigin-Name: e8d5caef260b171b4df7f6166e191fc763e25be5b94fc1e097cd5c4ec05604e4

15 months agoIgnore COLLATE operators when determining whether the result of a subexpression
drh [Wed, 20 Mar 2024 11:30:40 +0000 (11:30 +0000)] 
Ignore COLLATE operators when determining whether the result of a subexpression
should be shallow-copied or deep-copied.

FossilOrigin-Name: dd58d1178f840f0249cb3d84f44c9da0335ca6a44f064f6ad6ec68ec621556c5

15 months agoFix a harmless compiler warning in the randomjson.c extension.
drh [Wed, 20 Mar 2024 11:25:33 +0000 (11:25 +0000)] 
Fix a harmless compiler warning in the randomjson.c extension.

FossilOrigin-Name: a4c93512345f498e3e9aa1673c368bb9b0939b21bd492411b7eff581cd9a709a

15 months agoIf a term of an ORDER BY or GROUP BY contains an aggregate function or column,
drh [Wed, 20 Mar 2024 11:24:11 +0000 (11:24 +0000)] 
If a term of an ORDER BY or GROUP BY contains an aggregate function or column,
then it is not an alias that needs to be resolved, so don't try to.  This fixes
a harmless assertion found by dbsqlfuzz.

FossilOrigin-Name: e7ba2af5a1ae5d464ad4d4edfdf551bc237168e04784c07a229ba7b28c4f4695

15 months agoFix the SQLITE_ALLOW_ROWID_IN_VIEW bug-compatibility option so that it works
drh [Wed, 20 Mar 2024 11:04:38 +0000 (11:04 +0000)] 
Fix the SQLITE_ALLOW_ROWID_IN_VIEW bug-compatibility option so that it works
again.  Add the SQLITE_CONFIG_ROWID_IN_VIEW sqlite3_config() value
to optionally disable the bug-compatibility mode at start-time.  Enable
testing of SQLITE_ALLOW_ROWID_IN_VIEW.

FossilOrigin-Name: acc08353e27a960bf949cfc5f94e874a91e1c42fd7a26617dc24cf549fa9b120

15 months agoFix a problem involving infinities int the Kahan-Babushka-Neumaier summation algorithm.
drh [Tue, 19 Mar 2024 10:46:41 +0000 (10:46 +0000)] 
Fix a problem involving infinities int the Kahan-Babushka-Neumaier summation algorithm.

FossilOrigin-Name: 0984e5cd2574780dc1952e3daebafba9ddbb3b4937325117b922fdad0652db57

15 months agoSilently ignore redundant ON CONFLICT clauses in an UPSERT.
drh [Fri, 8 Mar 2024 14:16:20 +0000 (14:16 +0000)] 
Silently ignore redundant ON CONFLICT clauses in an UPSERT.

FossilOrigin-Name: e546d8c68539920ea7b88932e9553d908d6a1956b85e29518ee4f81035987403

17 months agoIn os_unix.c and os_win.c, do not allow xFetch() to return a pointer to a page buffer...
drh [Tue, 23 Jan 2024 16:21:07 +0000 (16:21 +0000)] 
In os_unix.c and os_win.c, do not allow xFetch() to return a pointer to a page buffer that is right at the end of the mapped region - if the database is corrupted in a specific way such a page buffer might be overread by several bytes.

FossilOrigin-Name: 198a1daae01dd9308f91eec1087279481ce0ff632bb3e5ab54cbf3738a903811

18 months agoUpdate #ifdef checks in pager.c and util.c to account for [0462a2612d1fc1d0] to resol...
stephan [Fri, 22 Dec 2023 15:42:09 +0000 (15:42 +0000)] 
Update #ifdef checks in pager.c and util.c to account for [0462a2612d1fc1d0] to resolve the build problem reported in [forum:9819032aac|forum post 9819032aac].

FossilOrigin-Name: 7374c2342e66b352c2098d401e7660b18a0cdf1a69c24386953b1331c2afcbbf

18 months agoWhen unable to resolve an identifier, change the Expr node into TK_NULL
drh [Tue, 19 Dec 2023 13:00:21 +0000 (13:00 +0000)] 
When unable to resolve an identifier, change the Expr node into TK_NULL
rather than TK_COLUMN, to prevent any downstream misuse of the non-existent
column.

FossilOrigin-Name: 8f770d14d3dca5eb38faa89c4cba269233aa45cc4a56176fdae22f14974ceeb2

18 months agoAvoid invoking sqlite3ExprColUsage() on an unresolve column reference.
drh [Wed, 13 Dec 2023 16:50:21 +0000 (16:50 +0000)] 
Avoid invoking sqlite3ExprColUsage() on an unresolve column reference.

FossilOrigin-Name: 6e0e2ee7c723582be5ad9126f5cd642c3cecf615c609bc0b87e914a6f5c0c904

18 months agoWorker1 Promiser API: when multiple db connections are active then use the requested...
stephan [Tue, 12 Dec 2023 17:55:20 +0000 (17:55 +0000)] 
Worker1 Promiser API: when multiple db connections are active then use the requested connection instead of always the first-opened connection. Bug reported in [forum:894c330e7f23b177|forum post 894c330e7f23b177].

FossilOrigin-Name: 3874e5a3282888b5b24835194d2f6c7b93f1ef456aa70013218b21038e831ba3

18 months agoDifferent fix for the fts5 COMMIT-following-OOM problem first fixed by [fba3129d...
dan [Mon, 11 Dec 2023 13:48:30 +0000 (13:48 +0000)] 
Different fix for the fts5 COMMIT-following-OOM problem first fixed by [fba3129d]. This one does not cause problems if an fts5 table is renamed and then dropped within the same transaction.

FossilOrigin-Name: 67da596d82ec0ed3c679da3be9d7379c557cd2fb83d7d833556107caf31327f6

19 months agoIncrease the patch level to 3.44.3.
drh [Wed, 29 Nov 2023 02:53:53 +0000 (02:53 +0000)] 
Increase the patch level to 3.44.3.

FossilOrigin-Name: bb4d35e2628320e187f96ca671cbbf68df51e423e93678b56f18983e93f91b9f

19 months agoReference count the Table passed into the OP_VCheck opcode.
drh [Wed, 29 Nov 2023 02:50:31 +0000 (02:50 +0000)] 
Reference count the Table passed into the OP_VCheck opcode.

FossilOrigin-Name: 79e6496bb18246c29970a0da53f2178b6de36c5d1f50da881a6846f188e8c04d

19 months agoVersion 3.44.2 version-3.44.2
drh [Fri, 24 Nov 2023 11:41:44 +0000 (11:41 +0000)] 
Version 3.44.2

FossilOrigin-Name: ebead0e7230cd33bcec9f95d2183069565b9e709bf745c9b5db65cc0cbf92c0f

19 months agoAnother assertion fault fix, similar to [a9443dbfbe25e588].
drh [Thu, 23 Nov 2023 12:12:54 +0000 (12:12 +0000)] 
Another assertion fault fix, similar to [a9443dbfbe25e588].

FossilOrigin-Name: f796da626b5c3b099cc246a8b46d92839922e34f398d673b0b03d7ee33a28a60

19 months agoFix harmless compiler warnings in debugging code.
drh [Thu, 23 Nov 2023 11:45:15 +0000 (11:45 +0000)] 
Fix harmless compiler warnings in debugging code.

FossilOrigin-Name: db40272c36c01d5eeb902daed2670d57ee858caae560785350aed2600b573c2d

19 months agoFix an fts5 problem that could occur when mixing regular and secure delete operations...
drh [Thu, 23 Nov 2023 11:29:00 +0000 (11:29 +0000)] 
Fix an fts5 problem that could occur when mixing regular and secure delete operations on a single table.

FossilOrigin-Name: 25fb5a540b1a61e1d0ff3d74ad7135bc53eb3fbe9f5352f98dd22dc7edd063bb

19 months agoIncrease the version number to 3.44.2.
drh [Thu, 23 Nov 2023 11:21:20 +0000 (11:21 +0000)] 
Increase the version number to 3.44.2.

FossilOrigin-Name: 73d3cb790950e317256f500e8bfd707a6156631628a80bcafce494e8bb1e1966

19 months agoFix output redirect bug reported in [forum:/forumposts/cbf4933cfeee74bb|the forum].
larrybr [Thu, 23 Nov 2023 07:06:21 +0000 (07:06 +0000)] 
Fix output redirect bug reported in [forum:/forumposts/cbf4933cfeee74bb|the forum].

FossilOrigin-Name: 2ab256bc0bb351c16feaf0d4917ad9c3f55e39821cc7d319d86c6f0752188af7

19 months agoCorrect the URL for loading sqlite3-worker1-bundler-friendly.mjs from sqlite3-worker1...
stephan [Wed, 22 Nov 2023 17:13:27 +0000 (17:13 +0000)] 
Correct the URL for loading sqlite3-worker1-bundler-friendly.mjs from sqlite3-worker1-promiser-bundler-friendly.js, so that the promiser can be used in bundler-using environments. Problem reported via email.

FossilOrigin-Name: b1128838f9508ba8e4b735a386c5dd42c1faf84705b95fb069ab724637341170

19 months agoVersion 3.44.1 version-3.44.1
drh [Wed, 22 Nov 2023 14:18:12 +0000 (14:18 +0000)] 
Version 3.44.1

FossilOrigin-Name: d295f48e8f367b066b881780c98bdf980a1d550397d5ba0b0e49842c95b3e8b4

19 months agoPickup minor stylistic changes related to console I/O and, for Windows builds, get...
larrybr [Tue, 21 Nov 2023 18:46:17 +0000 (18:46 +0000)] 
Pickup minor stylistic changes related to console I/O and, for Windows builds, get fact of UTF-16 translation into the sign-on banner. (a straight cherry-pick)

FossilOrigin-Name: d7a59e79467cf7aa13291c58f1cc4c1e2a51494bdd28661039421868f61088bd

19 months agoBack out an incorrect change to the sqlite3ExprCompareSkip() function from
drh [Mon, 20 Nov 2023 15:58:14 +0000 (15:58 +0000)] 
Back out an incorrect change to the sqlite3ExprCompareSkip() function from
long ago.

FossilOrigin-Name: 89658abbcd04e6f6d5a2139fa92091df1de72e56bdbb12aacebf9e9178c58e3b

19 months agoArrange to not compile unused console I/O function.
larrybr [Mon, 20 Nov 2023 13:59:44 +0000 (13:59 +0000)] 
Arrange to not compile unused console I/O function.

FossilOrigin-Name: 184a0cd2e855c5177948eaf754c82685e2fcd5a08488d4d3d7b5fc7537e007b4

19 months agoConvert an assert in OP_VCheck into a branch that aborts the opcode, as this
drh [Mon, 20 Nov 2023 13:12:05 +0000 (13:12 +0000)] 
Convert an assert in OP_VCheck into a branch that aborts the opcode, as this
can happen on some very obscure conditions, as discovered by dbsqlfuzz.

FossilOrigin-Name: 0d5f68717c829d4066c6af925c3a71f673ea34f14b1805388d1bdef152864d52

19 months agoCherry pick additional assert() fixes from trunk into the branch-3.44 branch.
drh [Mon, 20 Nov 2023 12:00:29 +0000 (12:00 +0000)] 
Cherry pick additional assert() fixes from trunk into the branch-3.44 branch.

FossilOrigin-Name: 6d8a8b700237d738e7b16dd844cf2514f0df7e2275bd9eab8de0a780e3687298

19 months agoFix an assert() in fts5 that could be true following an OOM or IO error in contentles...
drh [Mon, 20 Nov 2023 11:50:22 +0000 (11:50 +0000)] 
Fix an assert() in fts5 that could be true following an OOM or IO error in contentless-delete mode.

FossilOrigin-Name: 80a0bd7a692b7f08d0fddc5bc2a75e3c8146c54a08c19a70d0e1b6d0e1ac383e

19 months agoFix test 5.0 in shell1.test for Windows. (A double-quote wrapped single-quote needs...
larrybr [Sun, 19 Nov 2023 17:33:51 +0000 (17:33 +0000)] 
Fix test 5.0 in shell1.test for Windows. (A double-quote wrapped single-quote needs no further treatment to be recognized as a single single-quote.)

FossilOrigin-Name: aaa73400c41f382bbbd4ea32ad196d271c7a5e800bfee9afd998037a14fc89b9

19 months agoMerge changes to do Windows console I/O with UTF-16.
larrybr [Sat, 18 Nov 2023 22:10:40 +0000 (22:10 +0000)] 
Merge changes to do Windows console I/O with UTF-16.

FossilOrigin-Name: f782054e7ccdfb421a73acde6994f5046b99884924a508316a0d4a0dc9b03318

19 months agoCorrect conditional compilation issue seen with MSVC in the Win32 mutex subsystem.
drh [Sat, 18 Nov 2023 20:24:55 +0000 (20:24 +0000)] 
Correct conditional compilation issue seen with MSVC in the Win32 mutex subsystem.

FossilOrigin-Name: 6c069c5d664dca7908167e5759f952e407382b2669b25191167ad8d8fb03daa2

19 months agoCherrypick changes to simplify and make more rational how console I/O package feature... consio-3.44
larrybr [Thu, 16 Nov 2023 20:50:56 +0000 (20:50 +0000)] 
Cherrypick changes to simplify and make more rational how console I/O package features are selected.

FossilOrigin-Name: b20c9f1785e94af4b81dcbbc63c49a883ab4095ff251b19e814ab6ef7ff06f2b

19 months agoGet Fiddle build to succeed. (It runs, too, but not from changes here.)
larrybr [Wed, 15 Nov 2023 16:54:49 +0000 (16:54 +0000)] 
Get Fiddle build to succeed. (It runs, too, but not from changes here.)

FossilOrigin-Name: 957ebaa2be3056371d679f7a00aeba242db34218fb839ffd1d1197cad0c4a510

19 months agoChanges to console I/O for Fiddle build, to always defer to C library (as before...
larrybr [Wed, 15 Nov 2023 15:20:52 +0000 (15:20 +0000)] 
Changes to console I/O for Fiddle build, to always defer to C library (as before.) A WIP, pending testing with Fiddle build.

FossilOrigin-Name: 45b8061e7568ccca164fe000f1f0a0d984b1c28fad530bc9fdea35793a0f40bc

19 months agoCherry-pick some assert()s to cover misuse of *Put*() from 500+ shell.c callers.
larrybr [Tue, 14 Nov 2023 03:31:24 +0000 (03:31 +0000)] 
Cherry-pick some assert()s to cover misuse of *Put*() from 500+ shell.c callers.

FossilOrigin-Name: c1a53c28a4286c4c52fb78398d4dbf5c03de514a1fa9199bf0cfcd2cd3cc7cd9

19 months agoManual merge of branch-3.44 with 3 sources affected/created by console-io-lib changes.
larrybr [Mon, 13 Nov 2023 17:45:13 +0000 (17:45 +0000)] 
Manual merge of branch-3.44 with 3 sources affected/created by console-io-lib changes.

FossilOrigin-Name: 18ebcf117aad77fa968ff5c537c9b56c1342dea687377a72a02519412a6aa565

19 months agoRemove an incorrect ALWAYS() and NEVER().
drh [Mon, 13 Nov 2023 12:05:09 +0000 (12:05 +0000)] 
Remove an incorrect ALWAYS() and NEVER().

FossilOrigin-Name: 94f62093866823e013f976db8f80390bee2a9140f4cbec50d1ad8ded28f732ae

19 months agoFix another problem with mixed join types and the RIGHT JOIN strength-reduction optim...
drh [Fri, 10 Nov 2023 21:03:37 +0000 (21:03 +0000)] 
Fix another problem with mixed join types and the RIGHT JOIN strength-reduction optimization.

FossilOrigin-Name: 8f01f8b260bf70f047a720f1e61e578e500b87bdc2e867f8a8a521068a56c70c

19 months agoFix an obscure problem with the join-strength-reduction optimization that could occur...
drh [Fri, 10 Nov 2023 15:20:41 +0000 (15:20 +0000)] 
Fix an obscure problem with the join-strength-reduction optimization that could occur when mixing LEFT and RIGHT joins in the same query.

FossilOrigin-Name: dcf1c1378130538f1820263b4e62d06067d5ab30c07e2584c5c1b5082ede0d56

19 months agoExpose the missing SQLITE_SUBTYPE to wasm.
stephan [Fri, 10 Nov 2023 15:01:45 +0000 (15:01 +0000)] 
Expose the missing SQLITE_SUBTYPE to wasm.

FossilOrigin-Name: 7bebfe20e77a2b4edc47debede669fab5af9ed165e5feb59a532fb2c7475fcb0

19 months agoEnsure 8-byte alignment of data structues in sqlite3_database_file_object().
drh [Thu, 9 Nov 2023 18:41:42 +0000 (18:41 +0000)] 
Ensure 8-byte alignment of data structues in sqlite3_database_file_object().

FossilOrigin-Name: 3cfcaafaff181c7945cc659ff6d58a0d2232d49830a259f0510d833a7a5a824b

19 months agoExpose SQLITE_RESULT_SUBTYPE to wasm.
stephan [Thu, 9 Nov 2023 17:55:27 +0000 (17:55 +0000)] 
Expose SQLITE_RESULT_SUBTYPE to wasm.

FossilOrigin-Name: fc03988650645f0b08f1a3fb85b9ff54a04e0d7d27ca9f063198e43260826278

19 months agoAdd the SQLITE_RESULT_SUBTYPE flag for application-defined functions. Add
drh [Thu, 9 Nov 2023 17:42:46 +0000 (17:42 +0000)] 
Add the SQLITE_RESULT_SUBTYPE flag for application-defined functions.  Add
the -DSQLITE_STRICT_SUBTYPE=1 compile-time option that raises an error if
any function invokes sqlite3_result_subtype() without the SQLITE_RESULT_SUBTYPE
flag.  SQLITE_RESULT_SUBTYPE prevents an indexed value of that function from
being used to replace an equivalent expression, since the indexed expression
does not carry the subtype.

FossilOrigin-Name: 65a9cfc466d3d904af50fa5eba46d29c5a24e7dde06e5c50c03b343723be7441

19 months agoJSON5 bug fix: Escape double-quotes that occur inside of single-quoted strings.
drh [Thu, 9 Nov 2023 01:56:55 +0000 (01:56 +0000)] 
JSON5 bug fix:  Escape double-quotes that occur inside of single-quoted strings.

FossilOrigin-Name: 6cc57bb2ce92f64af59c569696d4fbd08183feffaeee560450d13370d60f96d5

19 months agoUpdate the documentation to the sqlite3_set_auxdata() and sqlite3_get_auxdata()
drh [Tue, 7 Nov 2023 19:15:55 +0000 (19:15 +0000)] 
Update the documentation to the sqlite3_set_auxdata() and sqlite3_get_auxdata()
routines to make it clear that they do not work as one might expect when they
are called during query planning, instead of during query execution.  The JSON
routines misuse those interfaces, so add a special flag to JSON routines that
prevents them from being invoked during query planning.

FossilOrigin-Name: 36259009c5b581ea692e8c86f505783336e4615bb5134e3afd5498f10eb36239

19 months agoUpdate the srctree-check.tcl script and child script so that they can be run
drh [Mon, 6 Nov 2023 19:08:46 +0000 (19:08 +0000)] 
Update the srctree-check.tcl script and child script so that they can be run
on a read-only source tree and so that if any inconsistencies are found, the
script returns a non-zero exit code and thus halts the build.

FossilOrigin-Name: a0cc7e8117abf03c8d0ab903f1f4b8ff48b6c0e6de85080c9d2a915fd1c16778

19 months agoFix an fts5 problem where a transaction consisting of (a) a DELETE on rowid X, (b...
drh [Mon, 6 Nov 2023 19:01:25 +0000 (19:01 +0000)] 
Fix an fts5 problem where a transaction consisting of (a) a DELETE on rowid X, (b) a prefix query, and (c) an INSERT on rowid X, could corrupt the index.

FossilOrigin-Name: 34af510a5615339f2963875eab94d4b07725e766c20819f82add19faa229d552

20 months agoUpdate the version number to 3.44.1
drh [Thu, 2 Nov 2023 11:14:43 +0000 (11:14 +0000)] 
Update the version number to 3.44.1

FossilOrigin-Name: 34f23c3d0d080fef82e3515ecb74257f68878c74fb0bdceac176a004aa1a84e9

20 months agoCLI to compile with older MSVC compiler.
drh [Thu, 2 Nov 2023 11:08:57 +0000 (11:08 +0000)] 
CLI to compile with older MSVC compiler.

FossilOrigin-Name: c8bf4f7a6a4c4f0f8cd21de25918f4d96f6831a145af4fb63e4b5984f79613b2

20 months agoVersion 3.44.0 version-3.44.0
drh [Wed, 1 Nov 2023 11:23:50 +0000 (11:23 +0000)] 
Version 3.44.0

FossilOrigin-Name: 17129ba1ff7f0daf37100ee82d507aef7827cf38de1866e2633096ae6ad81301

20 months agoFix harmless compiler warnings in test code.
drh [Tue, 31 Oct 2023 17:40:30 +0000 (17:40 +0000)] 
Fix harmless compiler warnings in test code.

FossilOrigin-Name: d1895dd8f5757a339f619f22b29c8a739398ded673bb9c93f1b8eb8a4b38f510

20 months agoFix a problem with SQLITE_ENABLE_FTS5 builds of the non-amalgamation testfixture...
dan [Tue, 31 Oct 2023 17:39:10 +0000 (17:39 +0000)] 
Fix a problem with SQLITE_ENABLE_FTS5 builds of the non-amalgamation testfixture.exe in Makefile.msc.

FossilOrigin-Name: 544091cc0f5b7395a89226629267c858ec53f18095aadb3e9307ef8ea718176e

20 months agoRemedy CLI non-UTF8 handling detection flaw [forum:/forumpost/fa0e00d36db5fe0a|noted...
larrybr [Mon, 30 Oct 2023 23:20:45 +0000 (23:20 +0000)] 
Remedy CLI non-UTF8 handling detection flaw [forum:/forumpost/fa0e00d36db5fe0a|noted in a forum post].

FossilOrigin-Name: a4c7954b9380dfd3599e521f7fd40b8b556a7d0268198b302146311d20c3b162

20 months agoRemedy CLI non-UTF8 handling detection flaw [forum:/forumpost/fa0e00d36db5fe0a|noted... win-utf8-io-split
larrybr [Mon, 30 Oct 2023 23:04:27 +0000 (23:04 +0000)] 
Remedy CLI non-UTF8 handling detection flaw [forum:/forumpost/fa0e00d36db5fe0a|noted in a forum post].

FossilOrigin-Name: 2666b80d2cf64a14d0482ee1ce0e8b2ff9e0c5bb21cd626470241a73a6555a3a

20 months agoUpdate the autoconf/Makefile.msc so that it aligns with Makefile.msc.
drh [Mon, 30 Oct 2023 20:35:33 +0000 (20:35 +0000)] 
Update the autoconf/Makefile.msc so that it aligns with Makefile.msc.

FossilOrigin-Name: c4f724de279dae1afd10d435ad61ed07c1e4658288457c50e4f9b2f4521bbe12

20 months agoDodge a nuisance warning from MSVC in CLI use of Prepared Statement Scan Status....
larrybr [Mon, 30 Oct 2023 19:50:20 +0000 (19:50 +0000)] 
Dodge a nuisance warning from MSVC in CLI use of Prepared Statement Scan Status. (Yes, C rules are fine.)

FossilOrigin-Name: 166c96d91dcc8c500a084d5703db103176ed5ec7d5f1334050cd66b3f1cd0e4f

20 months agoAdd a cast to i64 for an integer in an sqlite3OsWrite() offset
drh [Mon, 30 Oct 2023 19:03:17 +0000 (19:03 +0000)] 
Add a cast to i64 for an integer in an sqlite3OsWrite() offset
calculation.  The cast is not strictly necessary, but it helps human readers
see that the code is correct.

FossilOrigin-Name: 7564ff1ba2c2fba89106d1aa06cc5379e752f119f22370f2f155f24cc698dec6

20 months agoFix another comment typo. No code changes.
drh [Mon, 30 Oct 2023 18:48:03 +0000 (18:48 +0000)] 
Fix another comment typo.  No code changes.

FossilOrigin-Name: 3203256c0285ef2fea810d59978603bfd7e38151cbc42e1baddf84b57c56f638

20 months agoAdd FTS5 to default Makefile.msc builds. And UNKNOWN_SQL_FUNCTION and STMT_SCANSTATUS...
dan [Mon, 30 Oct 2023 18:17:29 +0000 (18:17 +0000)] 
Add FTS5 to default Makefile.msc builds. And UNKNOWN_SQL_FUNCTION and STMT_SCANSTATUS to default Makefile.msc shell builds.

FossilOrigin-Name: e41fde2fdb999b430561ac6d6ba150666ad1858e99c973f8dcd04a6934991032

20 months agoMake the new sqlite3_get_clientdata() and sqlite3_set_clientdata() interfaces
drh [Mon, 30 Oct 2023 18:09:14 +0000 (18:09 +0000)] 
Make the new sqlite3_get_clientdata() and sqlite3_set_clientdata() interfaces
available to run-time loaded extensions.

FossilOrigin-Name: 8fc9aa0f896a2676b73c41cefbff74c822a7106b56324558862dd0a2a1877eaf

20 months agoFix problems with previous commit on Makefile.msc. Also some win32-specific test... shell-build-changes
dan [Mon, 30 Oct 2023 18:07:18 +0000 (18:07 +0000)] 
Fix problems with previous commit on Makefile.msc. Also some win32-specific test failures in fts5misc.test.

FossilOrigin-Name: 527f2237a6fb5e2ac97afddd7c65c0afa971efc616cb3b738e7245ee0b8d9570

20 months agoFix typo in a comment. No code changes.
drh [Mon, 30 Oct 2023 17:56:27 +0000 (17:56 +0000)] 
Fix typo in a comment.  No code changes.

FossilOrigin-Name: 424ef9550abaab32f745dc955e8996d51836eaed737e24c4b4db811aa118ce5d

20 months agoAdd FTS5 to default Makefile.msc builds. And UNKNOWN_SQL_FUNCTION and STMT_SCANSTATUS...
dan [Mon, 30 Oct 2023 17:13:12 +0000 (17:13 +0000)] 
Add FTS5 to default Makefile.msc builds. And UNKNOWN_SQL_FUNCTION and STMT_SCANSTATUS to default Makefile.msc shell builds.

FossilOrigin-Name: bf99ebba23b6a72a0c02c5542574f409828343e89501cbe2112596ced063c6ab

20 months agoPredicate Windows CLI UTF-8 console I/O on a runtime capability check rather than...
larrybr [Mon, 30 Oct 2023 16:38:05 +0000 (16:38 +0000)] 
Predicate Windows CLI UTF-8 console I/O on a runtime capability check rather than an OS version check.

FossilOrigin-Name: 0058ea6a69103c1442bf5090553ce9bf77e06011a4960df754eb96144ced497d

20 months agoPredicate Windows CLI UTF-8 console I/O on a runtime capability check rather than...
larrybr [Mon, 30 Oct 2023 13:56:50 +0000 (13:56 +0000)] 
Predicate Windows CLI UTF-8 console I/O on a runtime capability check rather than an OS version check.

FossilOrigin-Name: f89d062f8890fffc957a354e966784031d561d0f8f5c174c1ccdcf77e66c32bd

20 months agoWith SQLITE_ENABLE_BLOCK_ATOMIC_WRITE enabled, if a transaction is committing
drh [Mon, 30 Oct 2023 12:09:48 +0000 (12:09 +0000)] 
With SQLITE_ENABLE_BLOCK_ATOMIC_WRITE enabled, if a transaction is committing
and there is a new freelist page at the end of the database file which would
cause the database file size to grow, ensure that page is written and the
file size grows before the block-atomic-write commits.  Fix for the
problem identified by [forum:/forumpost/3bd8d497b2|forum post 3bd8d497b2]

FossilOrigin-Name: c9fdd6805df04f05ef347e5a43506fd37a729c5924abb6e1103e871c4ac2d6dc

20 months agoFor Windows CLI, institute a version check to determine default MBCS or UTF-8 transla...
larrybr [Sun, 29 Oct 2023 20:05:18 +0000 (20:05 +0000)] 
For Windows CLI, institute a version check to determine default MBCS or UTF-8 translation on console I/O. (Default to UTF-8 where known possible.)

FossilOrigin-Name: ddc6ead6453e0f98943bd07aedd90d47bc2e9e9e27b008d493491168bea2b3f1

20 months agoSimplify code slightly. Improve comments on added code and its use.
larrybr [Sun, 29 Oct 2023 19:55:22 +0000 (19:55 +0000)] 
Simplify code slightly. Improve comments on added code and its use.

FossilOrigin-Name: 046c84296627382ee416f64b02b77a937b368e30b32e6b800de5a854810766f6

20 months agoProperly close a handle. Use a putatively effective runtime test for UTF-8 console...
larrybr [Sun, 29 Oct 2023 16:26:12 +0000 (16:26 +0000)] 
Properly close a handle. Use a putatively effective runtime test for UTF-8 console I/O capability. (This makes the version test useful mainly for avoiding a warning that UTF-8 console I/O could not be setup.)

FossilOrigin-Name: dc91eb91725f3db65c73725f1fbcf18a711cafb65b4fea3277aa0905a24df353

20 months agoCondition default UTF-8 console I/O for Windows builds on OS version 10 or more....
larrybr [Sun, 29 Oct 2023 00:24:22 +0000 (00:24 +0000)] 
Condition default UTF-8 console I/O for Windows builds on OS version 10 or more. This is to accomodate an IsValidCodePage() API which may happily report CP_UTF8 as a valid code page when the stock console cannot, in fact, do UTF-8 I/O.

FossilOrigin-Name: 6b9b2a886fd4d239c2e87c3f3809c011f77c0f60e0c279bbe4e1d1b53c609e2d

20 months agoLimit the range of integer unix timestamps in date4.test, since some systems
drh [Sat, 28 Oct 2023 16:19:21 +0000 (16:19 +0000)] 
Limit the range of integer unix timestamps in date4.test, since some systems
(RaspberryPI) cannot deal with timestamp values that exceed pow(2,31).

FossilOrigin-Name: 765290663b28e90a0494997baf023f9610a4ed32f0ff0099bf9fc3d485733fca

20 months agoUpdate documentation for sqlite3_errmsg() to try to make it clear that if
drh [Sat, 28 Oct 2023 11:53:14 +0000 (11:53 +0000)] 
Update documentation for sqlite3_errmsg() to try to make it clear that if
the schema of a database contains table names or similar with invalid UTF,
then the error message generated by SQLite might also contain invalid UTF.
No changes to code.

FossilOrigin-Name: 33ba13c7c4b6f9c5e64ea30c819718f2caea214afca945c9ed7075864f4aaa40

20 months agoSince SQLite considers NaN to be like NULL and NULL sorts before any integer,
drh [Sat, 28 Oct 2023 11:40:33 +0000 (11:40 +0000)] 
Since SQLite considers NaN to be like NULL and NULL sorts before any integer,
make sure the sqlite3IntFloatCompare() routine reports that the integer
argument is larger if the floating-point argument is NaN.

FossilOrigin-Name: de1cf31a34b0f21288e7e30434a06baf25ee579929107c22e65c57236577fc4a

20 months agoRemove the SQLITE_MAX_ALLOCATION_SIZE flag (set to 536mb) from the WASM and JNI build...
stephan [Sat, 28 Oct 2023 03:54:28 +0000 (03:54 +0000)] 
Remove the SQLITE_MAX_ALLOCATION_SIZE flag (set to 536mb) from the WASM and JNI builds because it can unduly limit db exports via sqlite3_serialize(), as reported in [forum:75524f7342c1ba45|forum post 75524f7342c1ba45]. It now defaults to whatever sqlite3.c uses, which is currently just shy of 2gb.

FossilOrigin-Name: f6e1137919243c5ce86725df64b40b7e12e82cbceaff210ca41616d620f0dd1b

20 months agoFix cosmetic flaw in SQLITE_TXN_* doc. (no code change)
larrybr [Fri, 27 Oct 2023 21:44:53 +0000 (21:44 +0000)] 
Fix cosmetic flaw in SQLITE_TXN_* doc. (no code change)

FossilOrigin-Name: 72d7c18f80f41529811f74855ac198681a0cfe7634225233ec4b8df219c2e73b

20 months agoDisable two rtree test cases for Linux-i686. We do not have that platform
drh [Fri, 27 Oct 2023 18:16:15 +0000 (18:16 +0000)] 
Disable two rtree test cases for Linux-i686.  We do not have that platform
available for testing.  The test cases work on all other 64-bit and 32-bit
platforms that we have at hand.  So there is no way for us to debug this
problem.  Better to disable the test.
[forum:/forumpost/ffcbf789b5386573|forum post ffcbf789b5386573].

FossilOrigin-Name: fed4d6e90baecca716429f95e1fab7930297afa2a191a87a0a87cb93910d1bce

20 months agoAdd makefile targets for fuzzcheck-asan and fuzzcheck-ubsan.
drh [Fri, 27 Oct 2023 17:40:46 +0000 (17:40 +0000)] 
Add makefile targets for fuzzcheck-asan and fuzzcheck-ubsan.

FossilOrigin-Name: 27fc14303a0c6942e8cf5017d66c7ff5fcbc700a6109a93768263370f608397e

20 months agoFix to Makefile.in so that the "tool-zip" target can be run from outside the source...
dan [Fri, 27 Oct 2023 15:31:44 +0000 (15:31 +0000)] 
Fix to Makefile.in so that the "tool-zip" target can be run from outside the source tree.

FossilOrigin-Name: cd118da9db0680fab8761ff44384639b9d564b67a5dfb1280ab72e44ff57714d

20 months agoCleanup shell.c comments. Hide -utf8 option, as it is undocumented and accepted only...
larrybr [Fri, 27 Oct 2023 13:59:05 +0000 (13:59 +0000)] 
Cleanup shell.c comments. Hide -utf8 option, as it is undocumented and accepted only for backward compatibility. No functional changes except for -help content.

FossilOrigin-Name: 3a87995560b5acbebeb5af407aa9eddf4c37c6a27ec9429ece0ea931918f9d9c

20 months agoBack out [2904fcbeebba9189], mostly. The page bitmap is needed even for a
drh [Fri, 27 Oct 2023 10:49:17 +0000 (10:49 +0000)] 
Back out [2904fcbeebba9189], mostly.  The page bitmap is needed even for a
partial integrity_check in order to avoid an infinite loops while walking the
database.

FossilOrigin-Name: dd6e03b37356e2961abd97f636402c09744c98c3033f3435503958c6219f9121

20 months agoIn CLI for Windows builds, do MBCS/UTF-8 translation independently for input and...
larrybr [Thu, 26 Oct 2023 18:41:13 +0000 (18:41 +0000)] 
In CLI for Windows builds, do MBCS/UTF-8 translation independently for input and output. (And cure an MSVC warning.)

FossilOrigin-Name: 80f0b6f9c76c049edaaaeedc1745978b9d5b02a9c34bbf64209266a154b2b0e3

20 months agoHandle utf8 mode restore better for redirected input or output. Move utf8 mode setup...
larrybr [Thu, 26 Oct 2023 18:24:41 +0000 (18:24 +0000)] 
Handle utf8 mode restore better for redirected input or output. Move utf8 mode setup to before any invocation command processing. Sync w/trunk.

FossilOrigin-Name: 59452e7c72de02c2b6d40974c91173d87fd5f6f2e28c0b1f6f53eb1a09693fb6

20 months agoEnhance the "tool-zip" makefile target on Windows so that it uses more
drh [Thu, 26 Oct 2023 17:30:54 +0000 (17:30 +0000)] 
Enhance the "tool-zip" makefile target on Windows so that it uses more
universally available commands to build the ZIP archive.  Fix other minor
issues with that makefile target at the same time.

FossilOrigin-Name: d2f2f9126562c24966b0e9bc3629b85950c20199c41250478ba1da68eb7a0046

20 months agoFurther enhancements to make sure the correct returnning trigger is run when
drh [Thu, 26 Oct 2023 16:59:22 +0000 (16:59 +0000)] 
Further enhancements to make sure the correct returnning trigger is run when
there are nested INSERT RETURNING statements.

FossilOrigin-Name: d83405e870b071540b56e76291bdce1388db80b860afd68a34e4233f6ff2a3ab

20 months agoHandle the case where a virtual table xBestIndex method called while coding a trigger...
dan [Thu, 26 Oct 2023 16:05:57 +0000 (16:05 +0000)] 
Handle the case where a virtual table xBestIndex method called while coding a trigger fired by a top-level statement with a RETURNING clause prepares a statement that also contains a RETURNING clause.

FossilOrigin-Name: ec6bffa3b0fbf7cdee852cb0208de1f5869dafd88e2ee64c23cec89634219adc

20 months agoReady for merge, but could use testing on some dusty old Windows machines.
larrybr [Thu, 26 Oct 2023 15:12:41 +0000 (15:12 +0000)] 
Ready for merge, but could use testing on some dusty old Windows machines.

FossilOrigin-Name: 20220615621e01ff83fd26133840e2553a6087bcb56bbb8e9bf1408dd881cd9b