Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
3003 commits
Select commit Hold shift + click to select a range
5dbbbf4
Remove some superfluous tabs and add the mkwasmbuilds ability to emit…
Sep 25, 2025
5ad6e7b
Fix the translation of "\v" in JSON5.
Sep 25, 2025
a4476ea
Overhaul the wasm build to (A) support more coexisting variants, e.g.…
Sep 25, 2025
3e7fe48
Replace ext/wasm/dist.make with mkdist.sh and get dist working with t…
Sep 25, 2025
ae48a24
wasm dist: add --snapshot flag, add -64 flag to include 64-bit builds…
Sep 25, 2025
51e3a14
Include writes to temp files by sort operations in the SQLITE_DBSTATU…
Sep 25, 2025
3574ec4
Add JSON table-valued functions jsonb_each() and jsonb_tree().
Sep 25, 2025
c125443
Build cleanups and dead code removal.
Sep 26, 2025
5ace5e0
More build docs. Add a speedtest1 64-bit build but it's not hooked up…
Sep 26, 2025
92f9355
On-demand loading of JSON virtual tables.
Sep 26, 2025
e040128
In c-pp.c, use (void)x instead of an empty if(x){} to flag unused arg…
Sep 26, 2025
a7a8d7f
Fix a harmless compiler warning.
Sep 26, 2025
c9f1759
Add new table-valued functions jsonb_each() and jsonb_tree() that wor…
Sep 26, 2025
6553a5d
Fix some integer overflow problems when handling corrupt hexdb dumps …
Sep 26, 2025
c839ea5
Docs and dead code removal in mkwasmbuilds.c.
Sep 26, 2025
8d2f3a1
Fix harmless integer overflows caused by over-sized integer constants in
Sep 26, 2025
3a94a00
Get wasmfs build working in the new setup. Disable the custom wasm lo…
Sep 26, 2025
80d74f0
In the regexp extension, limit the maximum value of integers in the
Sep 26, 2025
b62c26d
Limit the complexity of a REGEXP pattern using SQLITE_LIMIT_LIKE_PATT…
Sep 26, 2025
96c753e
Reinstate the Module.instantiateWasm() override and simplify how the …
Sep 26, 2025
42f9273
Get 64-bit builds of speedtest1.wasm running in order to better compa…
Sep 26, 2025
a34f87d
Clean up how the speedtest1 64-bit test/demo files are generated. Mak…
Sep 26, 2025
e309de2
Consolidate some duplicate code in mkwasmbuilds.c.
Sep 26, 2025
879066a
Delay replacing the wasm file name strings until they're needed. Add …
Sep 26, 2025
836e895
Latest upstream c-pp.c for the ability to process multiple inputs and…
Sep 27, 2025
5d0d30a
Add wasm.ptr to the module-symbols.html output.
Sep 27, 2025
4bdfae9
Remove and edit some comments.
Sep 27, 2025
4ac2118
Teach c-pp how to replace configure-script-like @tokens@, giving us a…
Sep 27, 2025
15e4074
Additional cleanup and refinement of the regexp.c extension.
Sep 27, 2025
18af487
Avoid integer overflow in memory allocation for the
Sep 27, 2025
943324c
Fix a bug in the ".dbtotxt" command of the CLI that causes a NULL poi…
Sep 27, 2025
c090488
Use sqlite3_malloc64() and sqlite3_realloc64() everywhere in the CLI.
Sep 27, 2025
4154910
ext/wasm/c-pp.c: add #savepoint support. Consolidate how the diverse …
Sep 27, 2025
54f2963
Rework the bounds calculations on generate_series() in an attempt to
Sep 27, 2025
0b0c873
Improve #if support in, and add #assert to, c-pp. Rename target=... p…
Sep 28, 2025
1d592e0
Internal js/wasm tooling doc updates.
Sep 28, 2025
c2f7be1
Fix harmless typo in a comment.
Sep 28, 2025
5b047a8
Refactor the generate_series extension. Compiles but does not yet work.
Sep 28, 2025
9ffb344
The generate_series rewrite is working better now, but is still not
Sep 28, 2025
d3cd2a2
All legacy tests are passing. Want to add new test cases before merg…
Sep 28, 2025
39bffbc
Use new c-pp features to simplify generation of the tester1 family of…
Sep 28, 2025
1bf80f2
Minor bug fixes. Many new test cases.
Sep 28, 2025
436c8e5
Remove the long-defunct wasmfs build of speedtest1 from index.html an…
Sep 28, 2025
36ba760
Revamp the implementation of generate_series to simplify and improve
Sep 28, 2025
b7f5885
Back out check-in [9abaa0ac2b304934] as the code removed there is nec…
Sep 28, 2025
381df87
Large JSON5 hexadecimal integer literals are positive unless preceded by
Sep 29, 2025
7e38287
Fix JSONB logic so that it correctly interprets large JSON5 hexadecimal
Sep 29, 2025
e6197c0
Improve whereSolver() so that it always finds a unique solution.
Sep 29, 2025
c49ff17
Merge the latest trunk enhancements into the dbstatus-spill branch
Sep 29, 2025
3eccaa7
Fix a buffer overread in the zipfile extension code.
Sep 29, 2025
8f6b797
Change the name to SQLITE_DBSTATUS_TEMPBUF_SPILL.
Sep 29, 2025
974b8d7
Fix a problem with the merge at [cb604efdb40da95a].
Sep 29, 2025
5b15123
Strengthen the fts5_locale() function against integer overflow attacks,
Sep 30, 2025
d05bf5a
Fix another potential buffer overread in the zipfile extension.
Sep 30, 2025
c8e6f62
Fix the new generate_series() to correctly deal with an explicit 0 as…
Sep 30, 2025
0f76b0a
Fix various compiler warnings.
Sep 30, 2025
4af7048
Enable the CLI to be compiled with SQLITE_OMIT_AUTHORIZATION.
Sep 30, 2025
a9af410
Fix a buffer overread in demo code in ext/misc/memvfs.c.
Oct 1, 2025
65ee59b
Prevent embedded 0x00 characters in the output strings from confusing
Oct 1, 2025
fa563ef
Add the --ifexists option to the CLI and to the ".open" command of th…
Oct 1, 2025
cbc3cd4
Fix a buffer overrun in the zipfile extension that could occur while …
Oct 2, 2025
b9c23fa
Correction to [ae303dab2f534e2c] to use the right loop over the solver.
Oct 2, 2025
7d973ac
Fix -DSQLITE_OS_OTHER=0 builds.
Oct 2, 2025
4defad2
In the ".open" command of the CLI if using the --new option with a URI
Oct 2, 2025
0d9ec8b
Harden the debugging vtab "delta_parse()" which is part of the
Oct 2, 2025
e2ebc36
Fix typo in the previous check-in. Remove surplus end-of-line whites…
Oct 2, 2025
1d574d3
Remove the memvfs.c extension, to prevent it from being misused.
Oct 2, 2025
275d08a
Minor clarifications to the JSONB format documentation.
Oct 3, 2025
d310393
Performance optimization in text formatter by using a hash table to l…
Oct 5, 2025
34775b6
Fix a syntax error in the tcl script part of [199b6567bb41cd].
Oct 5, 2025
833fb1e
Another small performance increase in the text format by using strchr…
Oct 5, 2025
d357d9d
Fix a subtle problem with short-circuit evaluation introduced by
Oct 6, 2025
566348f
Fix testrunner.tcl so that --help output goes to stdout, not stderr.
Oct 6, 2025
0611aee
New testrunner.tcl option "--case DISPLAYLNAME" only runs the single …
Oct 6, 2025
0ab87fc
Fix typo in the "testprefix" for walckptnoop.test
Oct 6, 2025
ad7118f
Update testrunner.tcl so that the new option is --cases rather than s…
Oct 6, 2025
6f7c977
Add info from the SQLITE_SCM_... macros to tool/version-info.c's --js…
Oct 6, 2025
87f5315
Fix typo in the previous check-in that prevented the script from runn…
Oct 6, 2025
35299c9
Change the testrunner.tcl option from "--case" (singular) to "--cases".
Oct 6, 2025
75ef68e
Avoid using randomblob() in walckptnoop.test, as it produces differen…
Oct 6, 2025
9804ed7
Avoid attempting to delete a file that is still open in sessionnoop2.…
Oct 6, 2025
7aa5271
Fix a minor problem with building sqlite3.c without manifest.tags.
Oct 6, 2025
9b6bc61
Fix some integer overflow warnings in the base64 and base85 extensions.
Oct 7, 2025
308831d
Improve the invariant checker module so that so that it added "+" before
Oct 7, 2025
6147a0f
Add test cases for the carray module.
Oct 7, 2025
b8d2ca1
Function name doc typo fixes for sqlite3_source_id() (sic.).
Oct 8, 2025
55085a2
The ".dbtotxt" command in the CLI should not fail if the database is
Oct 8, 2025
d397377
Fix an uninitialized variable problem in test1.c.
Oct 8, 2025
e15ef5b
Fix harmless integer overflow in the CLI when arguments to --lookasid…
Oct 8, 2025
cdaff85
Were we to choose to integrate the carray() table-valued function int…
Oct 8, 2025
ba5cce9
This is how the percentile() family of functions might be integrated …
Oct 8, 2025
01f5e6e
Add ENABLE compile-time options to enable carray() and median(). Hence
Oct 8, 2025
0df9db4
Make use of the new SQLITE_ENABLE_PERCENTILE in the wasm build.
Oct 8, 2025
8f2f5e4
Add the SQLITE_ prefix to the type constants used by sqlite3_carray_b…
Oct 8, 2025
3be9a9b
Move the carray() extension and the percentile extension into the
Oct 8, 2025
0f5a3f1
In the CLI, limit column widths specified by the ".width" command to
Oct 9, 2025
40d299a
Avoid corrupting the fts5 index if a value that was inserted via sqli…
Oct 9, 2025
b4fdfc2
Update c-pp.c and rename it to c-pp-lite.c to match its new upstream …
Oct 9, 2025
97fa2fe
Fix carrayfault.test so that it works with the new built-in CARRAY.
Oct 9, 2025
8080411
Fix the xBestIndex method on carray so that it gives a coherient quer…
Oct 10, 2025
7b34ca9
Fix the sqlite3_bind_blob() interface so that it sets the encoding of…
Oct 10, 2025
ea0d2ce
Avoid (apparently harmless) undefined behavior in CARRAY if the rowid
Oct 10, 2025
f9d5113
Fix the carrayfault.test script so that it works in configurations that
Oct 10, 2025
e33786f
Regenerate autoconf/Makefile.msc to squelch a 'make test' warning.
Oct 10, 2025
8c16706
Makefile updates to suppose carray() and percentile(). Add Carray to
Oct 10, 2025
80f0fcd
Fix harmless compiler warnings.
Oct 10, 2025
eeb2e03
Back out [8bf26c956e]. It is not required following [8e7da8cf50].
Oct 10, 2025
5013fd1
Provide alternative implementations of ceil() and floor() to the
Oct 10, 2025
1187816
Improvements to the (rarely used) home-grown varients of seriesCeil()
Oct 11, 2025
59e1ab5
Fix an assert() that could fail when reading a blob or text value lar…
Oct 11, 2025
e4eaf17
Remove an unused variable from the generate_series implementation.
Oct 11, 2025
ee4676b
Fix order of operations in the OP_Concat operator of the byte-code en…
Oct 12, 2025
9435603
Fix broken hyperlinks in the documentation.
Oct 12, 2025
c93270e
Enable CLI documentation for .imposter
Oct 13, 2025
a8bb50c
Fix a bug in concat_ws() in which an initial empty string was treated…
Oct 13, 2025
264bcad
Avoid integer overflows (a) when dealing with zeroblob(N) calls when …
Oct 13, 2025
898ac77
Merge all the latest trunk enhancements into the dbstatus-spill branch.
Oct 14, 2025
9f136fc
Fix a makefile typo which caused a build directory to not get mkdir'd…
Oct 14, 2025
5dbbe50
Add a section to ext/wasm/README.md about the dependency on wabt/wasm…
Oct 14, 2025
abe709b
Extra defenses against integer overflow in the decimal extension.
Oct 14, 2025
4472c96
Fix two links in ext/wasm/README.md.
Oct 14, 2025
53a6b7d
Make the new sqlite3_db_status64() API accessible to extensions.
Oct 14, 2025
efde2f6
Add the sqlite3_db_status64() interface and the
Oct 14, 2025
e7cf3fe
Add the test/testloadext.c loadable extension to test the ability to use
Oct 14, 2025
d6cb2cc
JS/WASM: Expose sqlite3_db_status64(), sqlite3changeset_apply_v3(), s…
Oct 14, 2025
f83df5b
Reestablish APIARMOR for the sqlite3_db_status() interface.
Oct 14, 2025
34c1e04
Fix memory allocation in the ".table" command of the .cli when the nu…
Oct 15, 2025
f66a060
Improve performance of the shell tool ".ar" command when it is given …
Oct 15, 2025
ff5d4c3
Resolve a valgrind-reported error in ext/wasm/c-pp-lite.c caused by s…
Oct 15, 2025
e826aa8
Minor JS doc updates. No code changes.
Oct 15, 2025
6eaeea0
Fix an off-by-one in c-pp-lite.c which could cause @token@-processed …
Oct 16, 2025
0a585a6
In dbpage.c, disable truncation on any update error, including errors
Oct 16, 2025
9c3fcd9
Improve performance of the shell tool ".ar" command when it is given …
Oct 16, 2025
9f36870
Resolve the MacOS-specific build issue reported in [forum:95edc7a8d7d…
Oct 16, 2025
31c86ca
Fix a minor memory leak in the CLI that can occur following an error
Oct 17, 2025
21c57ab
Increase the range of integer indexes in the the merge() family of
Oct 18, 2025
efe8ae5
Use 64-bit memory allocations everywhere in the expert extension.
Oct 18, 2025
d41f5ef
Reduce the maximum size of LIKE and GLOB patterns in the ossfuzz.c test
Oct 19, 2025
774ce0b
Back out [b144f875d6bddce6] and remove the former check for strchrnul…
Oct 21, 2025
984e446
Adjust some of the markdown in the LICENSE.md file so that it will ho…
Oct 22, 2025
d06a0be
Fix a faulty error message in the ext/misc/fileio.c extension.
Oct 23, 2025
4043096
Additional defenses against over-sized inputs in the (unused) amatch.c
Oct 23, 2025
95c188d
Limit the size of --hexdb files in the CLI to 2 billion lines, to avoid
Oct 24, 2025
bc2691d
In the CLI, improved error messages on input errors. Limit the size …
Oct 24, 2025
acdda10
Enhance the tokenizer so that it is able to deal with individual tokens
Oct 24, 2025
7adc9a5
Update the MSVC makefile for the amalgamation distribution.
Oct 24, 2025
4bb53ab
Make explicit that sqlite3_bind_pointer() and sqlite3_carray_bind() c…
Oct 24, 2025
9af334f
Document minor discrepancies in how sqlite3_bind_pointer() and sqlite…
Oct 24, 2025
033dbac
Fix [4e713558f6c6ea3d] so that it supports separate builds of rtree.
Oct 24, 2025
67fa337
ext/wasm/GNUmakefile: (A) When using a custom sqlite3.c, use sqlite3.…
Oct 24, 2025
3ba506d
ext/wasm: dependencies fix for parallel builds attempted immediately …
Oct 24, 2025
63ee854
Fix a duplicate SQLITE_API on sqlite3_carray_bind(), as reported in […
Oct 24, 2025
093b26e
New diagnostic SQL function "sqlite_file_info()" and its associated
Oct 24, 2025
2f9311c
Flesh out the sqlite_file_info() function further, and in particular
Oct 24, 2025
aeb886b
Easier to read /proc lock interpretation.
Oct 24, 2025
be4d0c2
Make it particularly clear in the wasm build output that unsupported …
Oct 24, 2025
003737d
Improvements to the design of the /proc lock analysis.
Oct 24, 2025
76db3a6
Stricter assert() statements on unixShmSystemLock().
Oct 25, 2025
f4e6605
Merge trunk enhancements into the file-info branch.
Oct 25, 2025
86319b8
New symbolic representation of posix advisory locking information
Oct 25, 2025
234c6c4
The sqlite_file_info() function should always return JSON, unless there
Oct 25, 2025
dcc07d3
Do not attempt to show posix-advisory-locking status on journal files.
Oct 25, 2025
ab29c24
Additional information about the unixShm shown.
Oct 25, 2025
0d859b4
Fix the CLI so that it does not try to open what might be an SQLite
Oct 25, 2025
c053b57
Merge the CLI deduceDatabaseType fix from trunk.
Oct 25, 2025
7be565f
Adjust unixPosixAdvisorLocks() to use redirectable system calls so that
Oct 25, 2025
726e836
Add additional information about unix file descriptors to the same da…
Oct 25, 2025
2b24d89
New --normal option for the ".open" command in the CLI. Also, when o…
Oct 25, 2025
ecbeefe
Fix a bug in sqlite_file_info() output: It was showing the "pal" for
Oct 25, 2025
a105989
Rename the file control to SQLITE_FCNTL_FILESTAT. Rename the SQL fun…
Oct 25, 2025
38113d3
Add the SQLITE_FCNTL_FILESTAT file control and the sqlite_filestat() SQL
Oct 25, 2025
3fceae3
Doc typo fix reported in the forum. No code changes.
Oct 26, 2025
f57d368
c-pp-lite: Fix another newline-related off-by-one which could cause n…
Oct 26, 2025
d4ead9b
A better/cleaner fix for [1c80ff88c0ce].
Oct 26, 2025
6b9230d
Merge the OPFS/SEE tests into trunk (where they should have been comm…
Oct 26, 2025
8ce786f
Fix sanitizer complaints in the regexp extension.
Oct 27, 2025
6e27846
Fix a minor over-allocation of heap memory in wal.c.
Oct 27, 2025
626351d
Implement an experimental defensive measure to try to prevent the -wa…
Oct 27, 2025
e34f35c
The unixIsSharingShmNode() function should always return false for the
Oct 27, 2025
db0d47b
Omit unnecessary branches from the unixIsSharingShmNode() implementat…
Oct 27, 2025
6cc222c
Additional comments explaining what unixIsSharingShmNode() does. No
Oct 28, 2025
9c07705
Enhance the CLI so that it can handle inputs larger than 2 billion li…
Oct 28, 2025
5a9ada5
Add enhanced resistance to corruption after posix advisory locks on the
Oct 28, 2025
ffbfc27
Fix an signed integer overflow problem that can occur when using an o…
Oct 28, 2025
74cd3c5
Typo fixes in LICENSE.md from BrickViking.
Oct 28, 2025
34b1bf1
Tiny cosmetic tweak to configure script output. No functional changes.
Oct 28, 2025
d443f0a
Fix a logic error introduced by [cea8bf79e18d55a8] which caused
Oct 29, 2025
7c86a03
Remove an OMIT_WAL from the wasm build because it breaks with the cur…
Oct 30, 2025
cb36dc3
Prevent a harmless signed integer overflow in the CLI if the argument
Oct 30, 2025
c5ff2aa
Fix the CLI ".dump" command so that it does not make duplicate
Oct 30, 2025
c6b86ba
Updates to the main README.md file.
Oct 30, 2025
4ebf491
Fix a harmless compiler warning associated with flexarrays.
Oct 30, 2025
f3b3964
Updates to the tool/warnings.sh script for better compiler warnings.
Oct 30, 2025
a8a99be
Fix a typo and improve wording in README.md
Oct 30, 2025
916fc11
Macro tweaks to get SQLITE_OMIT_WAL building. Remove some nearby stra…
Oct 30, 2025
3a61466
wasm: re-add SQLITE_OMIT_WAL to the c-pp-lite build flags.
Oct 30, 2025
7fb2545
Add (void) to two places for the sake of SQLITE_OMIT_WAL builds. Why …
Oct 30, 2025
41fda52
Another (void), as per [dd6edfc09434].
Oct 30, 2025
139ec38
Further improvements the ".dump" command to handle corner cases.
Oct 30, 2025
1ed6441
Add SQLITE_OMIT_WAL checks around some functions to avoid defining un…
Oct 30, 2025
da17de5
New assert() statements to help out static analyzers.
Oct 30, 2025
1c19c06
Fix the output of ".dump" in the CLI so that the sqlite_sequence table
Oct 31, 2025
63ab7c6
Update the main README.md file to use the robot-safe /rchvdwnld page …
Oct 31, 2025
a183595
Change the name of a file-scope constant array in carray.c so that it…
Oct 31, 2025
7f70085
Detect some cases of ambiguous column references in USING clauses tha…
Oct 31, 2025
b2b8ab6
Updates to the compile-for-windows.md document. No changes to code.
Oct 31, 2025
e5c8467
Fix ext/wasm/mkdist.sh to use ./version-info instead of ../../version…
Nov 1, 2025
0c747e1
Update the test/walthread.test testing script so that it uses a random
Nov 1, 2025
eaacb4a
Add pedantic OOM detection logic to some disused diagnostic and test …
Nov 2, 2025
15c6d88
Fix a harmless memory leak in the CLI caused by the --cmd option gene…
Nov 3, 2025
0dfa31d
Fix the test/speedtest.tcl script so that the CC= command-line option…
Nov 3, 2025
4733884
Update test result output from test/dbstatus2.test module so that it
Nov 3, 2025
d95fffc
Adjust the dbstatus2.test module so that it works on 32-bit builds in
Nov 3, 2025
f1c37a3
Add new column "cwd" to the jobs table in testrunner.db. For recordin…
Nov 3, 2025
1bf7eb3
Use the same compile-time options for the CLI in the auto-setup tarball
Nov 3, 2025
c2aa8e3
Version 3.51.0
Nov 4, 2025
ea0cda0
Kick off branch-3.51: bump version to 3.51.1 and cherrypick [0f712b6b…
Nov 9, 2025
de223ff
Merge various minor code and documentation fixes from trunk into the
Nov 13, 2025
2605119
Fix a problem in the EXISTS-to-JOIN optimization so
Nov 13, 2025
525d297
CLI shell: ensure that .dump propagates its error code on error.
Nov 13, 2025
8c7f142
Fix a problem in the xFilter() method of the fts5_vocab virtual table…
Nov 28, 2025
d261437
Fix a buffer overread in fts5 that might occur while processing a cor…
Nov 28, 2025
158436f
A better fix for the issue with RETURNING triggers on eponymous
Nov 28, 2025
a1de06a
Version 3.51.1
Nov 28, 2025
e20e6f5
Fix a potential UAF in sqlite3.oo1.DB.exec()'s teardown pieces.
Dec 1, 2025
334fa0e
Ensure that the EXISTS-to-JOIN break happens even if the inner loop is
Dec 5, 2025
fced18a
Increase the patch number to 3.51.2
Dec 5, 2025
55385fb
Fix an incorrect answer that might arise if a scalar query is both
Dec 9, 2025
6776708
Enhance the unixIsSharingShmNode() code (check-in [6385a1962c69c69c])…
Dec 15, 2025
323199b
Fix a memory leak in the fileio extension on windows. Other changes to
Dec 19, 2025
2b0579b
Fix a typo in check-in 0819fe670f9ceec7 that lead to incomplete prote…
Dec 31, 2025
bc9cebc
Use sqlite3_malloc64() in all places in the compress.c extension to a…
Dec 31, 2025
f8cae0b
Update the autoconf tarball Makefile.msc to align with the canonical …
Dec 31, 2025
632632c
Use 64-bit integers to track memory allocation sizes in the CSV exten…
Dec 31, 2025
a303f79
Ensure that loops created by the exists-to-join optimization use uniq…
Jan 2, 2026
b8c49d6
Fix yet another bug in the EXISTS-to-JOIN optimization.
Jan 3, 2026
3a621d8
Fix potential OOB read on the undocumented test function rtreenode() in
Jan 9, 2026
c51f318
Avoid signed integer overflow when an fts5 'merge' command is passed …
Jan 9, 2026
f3e0993
To ensure that the sqlite3_hard_heap_limit() call it makes is effecti…
Jan 9, 2026
ba76c16
Version 3.51.2
Jan 9, 2026
15cd670
Fix integer overflow problems and error reporting memory leaks in
Jan 13, 2026
bdf6109
Increase the version number to 3.51.3
Jan 13, 2026
f3cf123
Guard against oversized index entries in databases larger than 2GiB.
Jan 14, 2026
5ba5375
Prevent a malicious delta from causing an integer overflow in the
Jan 15, 2026
248ee2f
Avoid unsigned integer overflow in the delta_apply() extension function.
Jan 15, 2026
bae4055
Fix a buffer overrun that could occur when deleting rows in secure-de…
Jan 15, 2026
3c7a030
Avoid an obscure race condition between a checkpointer and a writer w…
Mar 6, 2026
a585374
Fix a problems with RIGHT JOINs.
Mar 12, 2026
a5333af
Version 3.51.3
Mar 13, 2026
b05e22b
Update SQLite to 3.51.3
azizcodesthings May 18, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions libsql-ffi/build.rs
Original file line number Diff line number Diff line change
Expand Up @@ -482,6 +482,7 @@ fn build_multiple_ciphers(out_path: &Path) -> PathBuf {
.define("SQLITE_SHELL_IS_UTF8", "OFF")
.define("SQLITE_USER_AUTHENTICATION", "OFF")
.define("SQLITE_SECURE_DELETE", "OFF")
.define("SQLITE_ENABLE_CARRAY", "OFF")
.define("SQLITE_ENABLE_COLUMN_METADATA", "ON")
.define("SQLITE_USE_URI", "ON")
.define("CMAKE_POSITION_INDEPENDENT_CODE", "ON")
Expand Down
28,914 changes: 19,664 additions & 9,250 deletions libsql-ffi/bundled/SQLite3MultipleCiphers/src/sqlite3.c

Large diffs are not rendered by default.

1,205 changes: 910 additions & 295 deletions libsql-ffi/bundled/SQLite3MultipleCiphers/src/sqlite3.h

Large diffs are not rendered by default.

10 changes: 3 additions & 7 deletions libsql-ffi/bundled/SQLite3MultipleCiphers/src/sqlite3mc.c
Original file line number Diff line number Diff line change
Expand Up @@ -67,15 +67,11 @@ void sqlite3mc_shutdown(void);
/*
** Enable the user authentication feature
*/
#if !SQLITE_USER_AUTHENTICATION
/* Option not defined or explicitly disabled */
#ifndef SQLITE_USER_AUTHENTICATION
/* Option not defined, therefore enable by default */
#define SQLITE_USER_AUTHENTICATION 1
#else
/* Option defined and disabled, therefore undefine option */
#undef SQLITE_USER_AUTHENTICATION
#define SQLITE_USER_AUTHENTICATION 0
#endif
#if !SQLITE_USER_AUTHENTICATION
#undef SQLITE_USER_AUTHENTICATION
#endif

#if defined(_WIN32) || defined(WIN32)
Expand Down
175 changes: 156 additions & 19 deletions libsql-ffi/bundled/bindings/bindgen.rs
Original file line number Diff line number Diff line change
Expand Up @@ -23,11 +23,13 @@ extern "C" {
) -> ::std::os::raw::c_int;
}

pub const __GNUC_VA_LIST: i32 = 1;
pub const SQLITE_VERSION: &[u8; 7] = b"3.45.1\0";
pub const SQLITE_VERSION_NUMBER: i32 = 3045001;
pub const SQLITE_VERSION: &[u8; 7] = b"3.51.3\0";
pub const SQLITE_VERSION_NUMBER: i32 = 3051003;
pub const SQLITE_SOURCE_ID: &[u8; 85] =
b"2024-01-30 16:01:20 e876e51a0ed5c5b3126f52e532044363a014bc594cfefa87ffb5b82257ccalt1\0";
b"2026-03-13 10:38:09 737ae4a34738ffa0c3ff7f9bb18df914dd1cad163f28fd6b6e114a344fe6alt1\0";
pub const SQLITE_SCM_BRANCH: &[u8; 12] = b"branch-3.51\0";
pub const SQLITE_SCM_TAGS: &[u8; 23] = b"release version-3.51.3\0";
pub const SQLITE_SCM_DATETIME: &[u8; 25] = b"2026-03-13T10:38:09.694Z\0";
pub const LIBSQL_VERSION: &[u8; 6] = b"0.2.3\0";
pub const SQLITE_OK: i32 = 0;
pub const SQLITE_ERROR: i32 = 1;
Expand Down Expand Up @@ -63,6 +65,9 @@ pub const SQLITE_DONE: i32 = 101;
pub const SQLITE_ERROR_MISSING_COLLSEQ: i32 = 257;
pub const SQLITE_ERROR_RETRY: i32 = 513;
pub const SQLITE_ERROR_SNAPSHOT: i32 = 769;
pub const SQLITE_ERROR_RESERVESIZE: i32 = 1025;
pub const SQLITE_ERROR_KEY: i32 = 1281;
pub const SQLITE_ERROR_UNABLE: i32 = 1537;
pub const SQLITE_IOERR_READ: i32 = 266;
pub const SQLITE_IOERR_SHORT_READ: i32 = 522;
pub const SQLITE_IOERR_WRITE: i32 = 778;
Expand Down Expand Up @@ -97,6 +102,8 @@ pub const SQLITE_IOERR_ROLLBACK_ATOMIC: i32 = 7946;
pub const SQLITE_IOERR_DATA: i32 = 8202;
pub const SQLITE_IOERR_CORRUPTFS: i32 = 8458;
pub const SQLITE_IOERR_IN_PAGE: i32 = 8714;
pub const SQLITE_IOERR_BADKEY: i32 = 8970;
pub const SQLITE_IOERR_CODEC: i32 = 9226;
pub const SQLITE_LOCKED_SHAREDCACHE: i32 = 262;
pub const SQLITE_LOCKED_VTAB: i32 = 518;
pub const SQLITE_BUSY_RECOVERY: i32 = 261;
Expand Down Expand Up @@ -175,6 +182,7 @@ pub const SQLITE_IOCAP_UNDELETABLE_WHEN_OPEN: i32 = 2048;
pub const SQLITE_IOCAP_POWERSAFE_OVERWRITE: i32 = 4096;
pub const SQLITE_IOCAP_IMMUTABLE: i32 = 8192;
pub const SQLITE_IOCAP_BATCH_ATOMIC: i32 = 16384;
pub const SQLITE_IOCAP_SUBPAGE_READ: i32 = 32768;
pub const SQLITE_LOCK_NONE: i32 = 0;
pub const SQLITE_LOCK_SHARED: i32 = 1;
pub const SQLITE_LOCK_RESERVED: i32 = 2;
Expand Down Expand Up @@ -224,6 +232,9 @@ pub const SQLITE_FCNTL_CKPT_START: i32 = 39;
pub const SQLITE_FCNTL_EXTERNAL_READER: i32 = 40;
pub const SQLITE_FCNTL_CKSM_FILE: i32 = 41;
pub const SQLITE_FCNTL_RESET_CACHE: i32 = 42;
pub const SQLITE_FCNTL_NULL_IO: i32 = 43;
pub const SQLITE_FCNTL_BLOCK_ON_CONNECT: i32 = 44;
pub const SQLITE_FCNTL_FILESTAT: i32 = 45;
pub const SQLITE_FCNTL_WAL_METHODS_POINTER: i32 = 129;
pub const SQLITE_GET_LOCKPROXYFILE: i32 = 2;
pub const SQLITE_SET_LOCKPROXYFILE: i32 = 3;
Expand Down Expand Up @@ -264,6 +275,7 @@ pub const SQLITE_CONFIG_STMTJRNL_SPILL: i32 = 26;
pub const SQLITE_CONFIG_SMALL_MALLOC: i32 = 27;
pub const SQLITE_CONFIG_SORTERREF_SIZE: i32 = 28;
pub const SQLITE_CONFIG_MEMDB_MAXSIZE: i32 = 29;
pub const SQLITE_CONFIG_ROWID_IN_VIEW: i32 = 30;
pub const SQLITE_DBCONFIG_MAINDBNAME: i32 = 1000;
pub const SQLITE_DBCONFIG_LOOKASIDE: i32 = 1001;
pub const SQLITE_DBCONFIG_ENABLE_FKEY: i32 = 1002;
Expand All @@ -284,7 +296,11 @@ pub const SQLITE_DBCONFIG_LEGACY_FILE_FORMAT: i32 = 1016;
pub const SQLITE_DBCONFIG_TRUSTED_SCHEMA: i32 = 1017;
pub const SQLITE_DBCONFIG_STMT_SCANSTATUS: i32 = 1018;
pub const SQLITE_DBCONFIG_REVERSE_SCANORDER: i32 = 1019;
pub const SQLITE_DBCONFIG_MAX: i32 = 1019;
pub const SQLITE_DBCONFIG_ENABLE_ATTACH_CREATE: i32 = 1020;
pub const SQLITE_DBCONFIG_ENABLE_ATTACH_WRITE: i32 = 1021;
pub const SQLITE_DBCONFIG_ENABLE_COMMENTS: i32 = 1022;
pub const SQLITE_DBCONFIG_MAX: i32 = 1022;
pub const SQLITE_SETLK_BLOCK_ON_CONNECT: i32 = 1;
pub const SQLITE_DENY: i32 = 1;
pub const SQLITE_IGNORE: i32 = 2;
pub const SQLITE_CREATE_INDEX: i32 = 1;
Expand Down Expand Up @@ -340,6 +356,7 @@ pub const SQLITE_LIMIT_WORKER_THREADS: i32 = 11;
pub const SQLITE_PREPARE_PERSISTENT: i32 = 1;
pub const SQLITE_PREPARE_NORMALIZE: i32 = 2;
pub const SQLITE_PREPARE_NO_VTAB: i32 = 4;
pub const SQLITE_PREPARE_DONT_LOG: i32 = 16;
pub const SQLITE_INTEGER: i32 = 1;
pub const SQLITE_FLOAT: i32 = 2;
pub const SQLITE_BLOB: i32 = 4;
Expand All @@ -357,12 +374,14 @@ pub const SQLITE_DIRECTONLY: i32 = 524288;
pub const SQLITE_SUBTYPE: i32 = 1048576;
pub const SQLITE_INNOCUOUS: i32 = 2097152;
pub const SQLITE_RESULT_SUBTYPE: i32 = 16777216;
pub const SQLITE_SELFORDER1: i32 = 33554432;
pub const SQLITE_WIN32_DATA_DIRECTORY_TYPE: i32 = 1;
pub const SQLITE_WIN32_TEMP_DIRECTORY_TYPE: i32 = 2;
pub const SQLITE_TXN_NONE: i32 = 0;
pub const SQLITE_TXN_READ: i32 = 1;
pub const SQLITE_TXN_WRITE: i32 = 2;
pub const SQLITE_INDEX_SCAN_UNIQUE: i32 = 1;
pub const SQLITE_INDEX_SCAN_HEX: i32 = 2;
pub const SQLITE_INDEX_CONSTRAINT_EQ: i32 = 2;
pub const SQLITE_INDEX_CONSTRAINT_GT: i32 = 4;
pub const SQLITE_INDEX_CONSTRAINT_LE: i32 = 8;
Expand Down Expand Up @@ -412,6 +431,7 @@ pub const SQLITE_TESTCTRL_RESERVE: i32 = 14;
pub const SQLITE_TESTCTRL_JSON_SELFCHECK: i32 = 14;
pub const SQLITE_TESTCTRL_OPTIMIZATIONS: i32 = 15;
pub const SQLITE_TESTCTRL_ISKEYWORD: i32 = 16;
pub const SQLITE_TESTCTRL_GETOPT: i32 = 16;
pub const SQLITE_TESTCTRL_SCRATCHMALLOC: i32 = 17;
pub const SQLITE_TESTCTRL_INTERNAL_FUNCTIONS: i32 = 17;
pub const SQLITE_TESTCTRL_LOCALTIME_FAULT: i32 = 18;
Expand Down Expand Up @@ -456,7 +476,8 @@ pub const SQLITE_DBSTATUS_CACHE_WRITE: i32 = 9;
pub const SQLITE_DBSTATUS_DEFERRED_FKS: i32 = 10;
pub const SQLITE_DBSTATUS_CACHE_USED_SHARED: i32 = 11;
pub const SQLITE_DBSTATUS_CACHE_SPILL: i32 = 12;
pub const SQLITE_DBSTATUS_MAX: i32 = 12;
pub const SQLITE_DBSTATUS_TEMPBUF_SPILL: i32 = 13;
pub const SQLITE_DBSTATUS_MAX: i32 = 13;
pub const SQLITE_STMTSTATUS_FULLSCAN_STEP: i32 = 1;
pub const SQLITE_STMTSTATUS_SORT: i32 = 2;
pub const SQLITE_STMTSTATUS_AUTOINDEX: i32 = 3;
Expand All @@ -469,6 +490,7 @@ pub const SQLITE_STMTSTATUS_MEMUSED: i32 = 99;
pub const LIBSQL_STMTSTATUS_BASE: i32 = 1024;
pub const LIBSQL_STMTSTATUS_ROWS_READ: i32 = 1025;
pub const LIBSQL_STMTSTATUS_ROWS_WRITTEN: i32 = 1026;
pub const SQLITE_CHECKPOINT_NOOP: i32 = -1;
pub const SQLITE_CHECKPOINT_PASSIVE: i32 = 0;
pub const SQLITE_CHECKPOINT_FULL: i32 = 1;
pub const SQLITE_CHECKPOINT_RESTART: i32 = 2;
Expand All @@ -493,6 +515,16 @@ pub const SQLITE_SERIALIZE_NOCOPY: i32 = 1;
pub const SQLITE_DESERIALIZE_FREEONCLOSE: i32 = 1;
pub const SQLITE_DESERIALIZE_RESIZEABLE: i32 = 2;
pub const SQLITE_DESERIALIZE_READONLY: i32 = 4;
pub const SQLITE_CARRAY_INT32: i32 = 0;
pub const SQLITE_CARRAY_INT64: i32 = 1;
pub const SQLITE_CARRAY_DOUBLE: i32 = 2;
pub const SQLITE_CARRAY_TEXT: i32 = 3;
pub const SQLITE_CARRAY_BLOB: i32 = 4;
pub const CARRAY_INT32: i32 = 0;
pub const CARRAY_INT64: i32 = 1;
pub const CARRAY_DOUBLE: i32 = 2;
pub const CARRAY_TEXT: i32 = 3;
pub const CARRAY_BLOB: i32 = 4;
pub const NOT_WITHIN: i32 = 0;
pub const PARTLY_WITHIN: i32 = 1;
pub const FULLY_WITHIN: i32 = 2;
Expand All @@ -502,8 +534,8 @@ pub const FTS5_TOKENIZE_DOCUMENT: i32 = 4;
pub const FTS5_TOKENIZE_AUX: i32 = 8;
pub const FTS5_TOKEN_COLOCATED: i32 = 1;
pub const WAL_SAVEPOINT_NDATA: i32 = 4;
pub type va_list = __builtin_va_list;
pub type __gnuc_va_list = __builtin_va_list;
pub type va_list = __builtin_va_list;
extern "C" {
pub static sqlite3_version: [::std::os::raw::c_char; 0usize];
}
Expand Down Expand Up @@ -920,6 +952,13 @@ extern "C" {
ms: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn sqlite3_setlk_timeout(
arg1: *mut sqlite3,
ms: ::std::os::raw::c_int,
flags: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn sqlite3_get_table(
db: *mut sqlite3,
Expand All @@ -940,7 +979,7 @@ extern "C" {
extern "C" {
pub fn sqlite3_vmprintf(
arg1: *const ::std::os::raw::c_char,
arg2: *mut __va_list_tag,
arg2: va_list,
) -> *mut ::std::os::raw::c_char;
}
extern "C" {
Expand All @@ -956,7 +995,7 @@ extern "C" {
arg1: ::std::os::raw::c_int,
arg2: *mut ::std::os::raw::c_char,
arg3: *const ::std::os::raw::c_char,
arg4: *mut __va_list_tag,
arg4: va_list,
) -> *mut ::std::os::raw::c_char;
}
extern "C" {
Expand Down Expand Up @@ -1186,6 +1225,13 @@ extern "C" {
extern "C" {
pub fn sqlite3_error_offset(db: *mut sqlite3) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn sqlite3_set_errmsg(
db: *mut sqlite3,
errcode: ::std::os::raw::c_int,
zErrMsg: *const ::std::os::raw::c_char,
) -> ::std::os::raw::c_int;
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct sqlite3_stmt {
Expand Down Expand Up @@ -2506,7 +2552,7 @@ extern "C" {
pub fn sqlite3_str_vappendf(
arg1: *mut sqlite3_str,
zFormat: *const ::std::os::raw::c_char,
arg2: *mut __va_list_tag,
arg2: va_list,
);
}
extern "C" {
Expand Down Expand Up @@ -2563,6 +2609,15 @@ extern "C" {
resetFlg: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn sqlite3_db_status64(
arg1: *mut sqlite3,
arg2: ::std::os::raw::c_int,
arg3: *mut sqlite3_int64,
arg4: *mut sqlite3_int64,
arg5: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn sqlite3_stmt_status(
arg1: *mut sqlite3_stmt,
Expand Down Expand Up @@ -2953,6 +3008,16 @@ extern "C" {
mFlags: ::std::os::raw::c_uint,
) -> ::std::os::raw::c_int;
}
extern "C" {
pub fn sqlite3_carray_bind(
pStmt: *mut sqlite3_stmt,
i: ::std::os::raw::c_int,
aData: *mut ::std::os::raw::c_void,
nData: ::std::os::raw::c_int,
mFlags: ::std::os::raw::c_int,
xDel: ::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>,
) -> ::std::os::raw::c_int;
}
pub type sqlite3_rtree_dbl = f64;
extern "C" {
pub fn sqlite3_rtree_geometry_callback(
Expand Down Expand Up @@ -3188,6 +3253,34 @@ pub struct Fts5ExtensionApi {
arg3: *mut ::std::os::raw::c_int,
) -> ::std::os::raw::c_int,
>,
pub xColumnLocale: ::std::option::Option<
unsafe extern "C" fn(
arg1: *mut Fts5Context,
iCol: ::std::os::raw::c_int,
pz: *mut *const ::std::os::raw::c_char,
pn: *mut ::std::os::raw::c_int,
) -> ::std::os::raw::c_int,
>,
pub xTokenize_v2: ::std::option::Option<
unsafe extern "C" fn(
arg1: *mut Fts5Context,
pText: *const ::std::os::raw::c_char,
nText: ::std::os::raw::c_int,
pLocale: *const ::std::os::raw::c_char,
nLocale: ::std::os::raw::c_int,
pCtx: *mut ::std::os::raw::c_void,
xToken: ::std::option::Option<
unsafe extern "C" fn(
arg1: *mut ::std::os::raw::c_void,
arg2: ::std::os::raw::c_int,
arg3: *const ::std::os::raw::c_char,
arg4: ::std::os::raw::c_int,
arg5: ::std::os::raw::c_int,
arg6: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int,
>,
) -> ::std::os::raw::c_int,
>,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
Expand All @@ -3196,6 +3289,41 @@ pub struct Fts5Tokenizer {
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct fts5_tokenizer_v2 {
pub iVersion: ::std::os::raw::c_int,
pub xCreate: ::std::option::Option<
unsafe extern "C" fn(
arg1: *mut ::std::os::raw::c_void,
azArg: *mut *const ::std::os::raw::c_char,
nArg: ::std::os::raw::c_int,
ppOut: *mut *mut Fts5Tokenizer,
) -> ::std::os::raw::c_int,
>,
pub xDelete: ::std::option::Option<unsafe extern "C" fn(arg1: *mut Fts5Tokenizer)>,
pub xTokenize: ::std::option::Option<
unsafe extern "C" fn(
arg1: *mut Fts5Tokenizer,
pCtx: *mut ::std::os::raw::c_void,
flags: ::std::os::raw::c_int,
pText: *const ::std::os::raw::c_char,
nText: ::std::os::raw::c_int,
pLocale: *const ::std::os::raw::c_char,
nLocale: ::std::os::raw::c_int,
xToken: ::std::option::Option<
unsafe extern "C" fn(
pCtx: *mut ::std::os::raw::c_void,
tflags: ::std::os::raw::c_int,
pToken: *const ::std::os::raw::c_char,
nToken: ::std::os::raw::c_int,
iStart: ::std::os::raw::c_int,
iEnd: ::std::os::raw::c_int,
) -> ::std::os::raw::c_int,
>,
) -> ::std::os::raw::c_int,
>,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct fts5_tokenizer {
pub xCreate: ::std::option::Option<
unsafe extern "C" fn(
Expand Down Expand Up @@ -3256,6 +3384,23 @@ pub struct fts5_api {
xDestroy: ::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>,
) -> ::std::os::raw::c_int,
>,
pub xCreateTokenizer_v2: ::std::option::Option<
unsafe extern "C" fn(
pApi: *mut fts5_api,
zName: *const ::std::os::raw::c_char,
pUserData: *mut ::std::os::raw::c_void,
pTokenizer: *mut fts5_tokenizer_v2,
xDestroy: ::std::option::Option<unsafe extern "C" fn(arg1: *mut ::std::os::raw::c_void)>,
) -> ::std::os::raw::c_int,
>,
pub xFindTokenizer_v2: ::std::option::Option<
unsafe extern "C" fn(
pApi: *mut fts5_api,
zName: *const ::std::os::raw::c_char,
ppUserData: *mut *mut ::std::os::raw::c_void,
ppTokenizer: *mut *mut fts5_tokenizer_v2,
) -> ::std::os::raw::c_int,
>,
}
#[repr(C)]
#[derive(Debug, Copy, Clone)]
Expand Down Expand Up @@ -3574,12 +3719,4 @@ extern "C" {
extern "C" {
pub static sqlite3_wal_manager: libsql_wal_manager;
}
pub type __builtin_va_list = [__va_list_tag; 1usize];
#[repr(C)]
#[derive(Debug, Copy, Clone)]
pub struct __va_list_tag {
pub gp_offset: ::std::os::raw::c_uint,
pub fp_offset: ::std::os::raw::c_uint,
pub overflow_arg_area: *mut ::std::os::raw::c_void,
pub reg_save_area: *mut ::std::os::raw::c_void,
}
pub type __builtin_va_list = *mut ::std::os::raw::c_char;
Loading
Loading