1
0
mirror of https://github.com/sqlite/sqlite.git synced 2025-09-05 10:44:27 +03:00
Commit Graph

30276 Commits

Author SHA1 Message Date
drh
5e972ddd9f Add an assert() to prove that sqlite3_prepare() does not return
SQLITE_ERROR_RETRY.

FossilOrigin-Name: 6c6a8a596f5d578cc7d35c577608492c0314cdb84ed67b9f068d90fb0b42f4de
2025-08-20 23:13:49 +00:00
drh
51d3e6d51c Change a newly unreachable branch into an ALWAYS().
FossilOrigin-Name: 99556be3fd99e6b7c520b0ae2090f59c6f58375750f9d571f9f586bce0a21504
2025-08-20 21:12:40 +00:00
dan
1be5689087 Avoid returning SQLITE_ERROR_RETRY if collation sequences associated with the table's PK cannot be found when creating an index. Possible fix for [forum:aa61ab56ad | forum post aa61ab56ad].
FossilOrigin-Name: ac649e5b9ca9b8f7729defa8d646df8c0cb57977a5eedcfa2cf1147d109a17f1
2025-08-20 15:42:23 +00:00
dan
c30e1a10ef Fix a problem with SQLITE_CHANGESET_CONFLICT conflicts caused by DELETE triggers within a call to sqlite3changset_apply_v2() with SQLITE_CHANGESETAPPLY_IGNORENOOP specified.
FossilOrigin-Name: 138e2aab43ac07aaf8c5389105ff6d3e107ff2d35badcb48233664fcb9661471
2025-08-20 11:21:35 +00:00
stephan
4a27581f14 In builds without HAVE_FCHMOD (e.g. WASI), make the chmod() of temp files a no-op, analog to how lack of HAVE_FCHOWN is handled, as discussed in [forum:98d5158d3fdd7a41 | forum post 98d5158d3f].
FossilOrigin-Name: 7d13e8e403ba00d37b950caa359d74452319247495284d252efa6473bad15b64
2025-08-20 09:43:15 +00:00
dan
697d29ea49 Fix a problem causing an SQLITE_CHANGESET_DATA conflict of a DELETE operation to be incorrectly ignored if the SQLITE_CHANGESETAPPLY_IGNORENOOP is specified.
FossilOrigin-Name: 78b543f85ac6643f3b69bf1250c6362f00e030f93f460ef7d04902682ef64ee9
2025-08-19 21:35:23 +00:00
stephan
7f84ce0ea9 Add a doc sentence about sqlite3_set_clientdata()'s result value, per request in [forum:bda6c22b6a | forum post bda6c22b6a]. No code changes.
FossilOrigin-Name: c664cee321fc449283ecfc073c45057c078299be33dc0c170b156d81a6698b55
2025-08-16 10:17:04 +00:00
dan
a6c95406c1 Avoid depending on HAVE_STDINT_H and SQLITE_PTRSIZE and other things in non-amalgamation builds of fts5.
FossilOrigin-Name: 309fdd496673bf58984fb16aef3d4cc2ad8c9f6dad7687509f4d708fed5ba41b
2025-08-14 19:36:59 +00:00
stephan
e3fc1fc8dd Minor internal cleanups in the configure script. No behavioral changes.
FossilOrigin-Name: c42269e5ce3688fccee16cf35e1101f36afc3ccc19bef57b177d46c84db2435a
2025-08-13 19:59:37 +00:00
dan
6f097125cd Have cksumvfs write checksums to the database file only, not the wal file. Writing them to the wal file breaks wal file recovery.
FossilOrigin-Name: e3bd1feccaee8ff2f68b7b863769dd739e8a434fd32fed73deeeec885628311c
2025-08-13 19:13:16 +00:00
dan
0e77c3fa4d In cksumvfs, do not write checksums to the wal file, as this prevents recovery from working.
FossilOrigin-Name: 5bf48c7e31904f1f7048499c630801846df89f262b32ea1e49fb6e039eaad11a
2025-08-13 18:37:41 +00:00
stephan
527062ac5e Minor autosetup/README.md tweaks.
FossilOrigin-Name: bd7530bf6afdad391b223651632e1b4d59ab5ec806c7a94daadc7f09091321f4
2025-08-13 18:30:42 +00:00
stephan
656563cce9 Move the forced NDEBUG in fts3Int.h up above the #include of assert.h, as reported in [forum:8f16dd9480aad85f | forum post 8f16dd9480aad85f].
FossilOrigin-Name: 3b06d1c9b6c03f38029a8b98fef6253647878c0f8b05447ec0c8122f189c90dc
2025-08-13 17:58:47 +00:00
stephan
6cebfa56cc Doc updates in the configure script. No functional changes.
FossilOrigin-Name: 47c4a2ddd1966aa8564e105fc1f2ba3c9c1668b44d4979424f65148d7976064c
2025-08-13 16:49:55 +00:00
dan
8e875fa3bd Fix a problem with the checksum-vfs and direct-overflow-reads. Forum post [forum:350e147cd1 | 350e147cd1].
FossilOrigin-Name: 7b7ce5f17fd63932a050b917b4356c23eec6040d1c4f51136393d7c6e3d40a63
2025-08-13 14:40:24 +00:00
dan
c5c9c6093b Fix a problem with the checksum-vfs and direct-overflow-reads.
FossilOrigin-Name: 8288edb9f930206f117823cf1d18af632dc6adbd7c4c3b9bcfc252e1a5e5b9cd
2025-08-13 14:35:14 +00:00
stephan
16478dbfdd Doc cleanups in main.mk. No functional changes.
FossilOrigin-Name: 839c998443880161af06b9f7470ebfc828251c3c1accdae5f0fbbcc13408474c
2025-08-13 11:46:05 +00:00
dan
a939a635a2 Fix a problem with reading wal mode databases from UNC shares on windows introduced by [e88212b10a7829ff].
FossilOrigin-Name: f341e7812984b41acd7dd2dd795a1716a8826af4326578dcdf7d7fdd55124ceb
2025-08-12 19:02:48 +00:00
dan
3f85939bf0 Fix a problem building testfixture on non SQLITE_OS_WIN platforms.
FossilOrigin-Name: 9e6fa73467892eb2333c0a94ca38b66b7cc0432326de93ff131ecde4c165114e
2025-08-12 18:57:02 +00:00
dan
b1406a6550 On windows, when opening a UNC path, fall back to using a single file handle shared between all connections for locking.
FossilOrigin-Name: 5c0202d96c3a20a2cbcd38eba5e62371606894a0cbc2da4f60e10a1b5fa7bd04
2025-08-12 17:55:34 +00:00
drh
1ecc135cc5 The off-by-one fix at [3e627d66ebdef8df] is insufficient. An index
can hold twice as many columns as a table, if the table is a WITHOUT ROWID
table.  The limit should be twice the maximum, not just one more than the
maximum.  Problem discovered by OSSFuzz.

FossilOrigin-Name: a836126bbec5c14432ed7fc7e9e6f8ebcd5dd1116d3ac8a9a0d25c8f62cc51fe
2025-08-11 13:17:10 +00:00
dan
9081b89720 Replace some 32-bit arithmetic in fts3_write.c with 64-bit to avoid the possibility of integer overflow.
FossilOrigin-Name: 6711110b1c7589311f012deee4d4dd5b771fa44ad328b471c9ef583960795199
2025-08-11 10:54:39 +00:00
stephan
88f7807fa6 Add an explicit call to sqlite3_initialize() to sqlite3_rsync so that it works when built with SQLITE_OMIT_AUTOINIT, as suggested in [forum:c4ec6b33097b8536 | forum post c4ec6b33097b8536].
FossilOrigin-Name: 8c9db6237154d1c153916ed821f576f91b353bf988182127d2a619506707d6bd
2025-08-07 20:20:22 +00:00
stephan
11ba513fe5 Skip checking for dlopen() on mingw builds and those which include "windows" in their host tuple, as suggested in [forum:2436c8ffed | forum post 2436c8ffed]. Those environments identify as Windows for SQLite's purposes so use LoadLibrary().
FossilOrigin-Name: 69b87d4fa8089ef6101e976131dfd5c47dbc3d8c01a7e7d90a444b7a4794f78b
2025-08-06 19:16:16 +00:00
drh
e7440380c2 Do not allow the number of terms in an ORDER BY or GROUP BY clause to
exceed the maximum number of columns in a table.

FossilOrigin-Name: 139e587c7b349e771d67a8b4ee02ab3ad5d5712d4ff4713dad63cb765bdee248
2025-08-06 19:12:10 +00:00
drh
e6061cba7f Fix Windows makefile breakage caused by [ae9d7c9c922bb241].
FossilOrigin-Name: c41324139d6a75b0d37aeec2b0572c63207dd0b06e6a99e4fb221be564e73024
2025-08-06 19:05:39 +00:00
stephan
5d06c6b3f1 Add *.obj to the make clean target for the sake of the Unix-on-Windows environments.
FossilOrigin-Name: da07e0c02fe7de7b67f2564c29f49f251ae2374c0e269d246bd13e68a9a73328
2025-08-06 16:51:12 +00:00
stephan
de048aeda9 Extend the sqlite3_rsync PATH to include /opt/local/bin, per request in [forum:ca3c1bb7ca8e03 | forum post ca3c1bb7ca8e03].
FossilOrigin-Name: 79a14a5ebd0e8a0aa7f7bb180fcaa348a3ecd046662e3ee05a34f2c9a7db3dd6
2025-08-06 15:57:44 +00:00
drh
7270a56fdf Minor bug fixes in the script added by the previous check-in
FossilOrigin-Name: 2e1a2db3f92b0bd484d979b422fe28e86732121594d190b76dbf46f5d7533643
2025-08-06 12:47:58 +00:00
drh
aa86b2a373 Add a script to build ARM64EC binaries on Windows11 for ARM64.
FossilOrigin-Name: 2d5b74b84a9c778183a11070623e89b553ba9cde905b779dbf115ea95aa0ca9b
2025-08-06 12:43:06 +00:00
drh
ff1d5e5bb8 Fix a possible printf() of a NULL string in fuzzcheck. (Passing a NULL to
"%s" in SQLite's internal printf() prints the text
"NULL", but it apparently segfaults glibc.  Whatever.)
[forum:/forumpost/e07d56579b|Forum post e07d56579b].

FossilOrigin-Name: 4ec69baf4f2a75585b92388cbc352836116381dce3f2d44a3b0f7d3360a17cf0
2025-08-05 23:01:31 +00:00
drh
cd70a44d45 Remove the <i>experimental</i> lsm1 extension from trunk, in as much as
readers were thinking that this was a supported extension and were reporting
bugs against it.

FossilOrigin-Name: ae9d7c9c922bb241363aa690b42b9664c4ad6e76ed5ce474daf1ab44461bc6a3
2025-08-05 12:01:43 +00:00
drh
332eb8e63c Add bounds checking and error messages and improved comments
to the (unused) zorder extension function.
[forum:/forumpost/e3f1ede174|Forum post e3f1ede174]

FossilOrigin-Name: 6bb717acf706e6ffd4671660ca78237e6a42863f344518e6d21065bf735f971e
2025-08-05 10:54:56 +00:00
drh
f9c2cff2fe Improved defenses against corrupt ZIP archives in the zipfile extension.
FossilOrigin-Name: 642e89191deaf75db236102248c662aeef65bcd3dcbdfea694256583556be75f
2025-08-05 01:53:03 +00:00
drh
eff534e1a5 Back out a recently added NEVER().
FossilOrigin-Name: 4fcdd5bdb061d550b4a35594eb16c9a1699c76caf1d906f1781b4f9cb29ac80c
2025-08-05 00:16:40 +00:00
drh
a37bf61539 Fix a bug in the fuzzcheck.c test program introduced by [1cccea0508f5c8b8].
FossilOrigin-Name: 90b217e11c988785d19b8efbba435250c120837492f430cf16d6d4524dd55136
2025-08-04 23:37:48 +00:00
drh
d7d77eb56d When doing an indexed row-value comparison using an IN operator where the
order of the columns in the row-value need to be rearranged in order to match
the index, be sure to make affinity conversions before the rearranging of
columns so that the correct affinity is applied.  Fix for the bug
reported by [forum:/forumpost/eab63506cf|forum post eab63506cf].  This
problem goes back almost nine years to [ddb5f0558c445699].

FossilOrigin-Name: 8800c13deca3717c8a9bed42ef5f09752e4ca8a31adfb4ab0545e0e2b5684bd0
2025-08-04 23:05:35 +00:00
dan
82b08cc8ef Add an assert() to verify that IN_INDEX_NOOP is not used for vector operations.
FossilOrigin-Name: 49c587c6d204841a3d26f183812913ebd585006259040fdf7ba68346cc75580a
2025-08-04 20:48:37 +00:00
drh
e318c4573b Remove the "experimental" mark the snapshot interfaces.
FossilOrigin-Name: 015dc43f628a6f5054152b05b20eb03b6a1153231f824c910a4416792af05272
2025-08-04 19:35:20 +00:00
drh
8725bf916d Fix harmless compiler warnings arising from [1cccea0508f5c8b8].
FossilOrigin-Name: d682557464a6069a93f890bb0aa983cea020ccde8261335ceeab19b9b6423863
2025-08-04 11:50:41 +00:00
stephan
1f4c281b0b Minor doc typo fix in sqliteLimit.h.
FossilOrigin-Name: 8bb315ef7429a60899f5afe878a3b1aa146b18eef2ac9f4d6eca98587a2255cd
2025-08-04 11:20:31 +00:00
stephan
1cf61ce636 Add a note to sqlite3_deserialize() that a schema name of NULL implies the main db, a former shortcoming pointed out in [forum:0543d8aa8e|forum post 0543d8aa8e].
FossilOrigin-Name: 50234bc9e9fe58daf820ed5a1355f1d173728b5d33a7534244f1acff974baa30
2025-08-03 08:56:16 +00:00
drh
cd552cf99f Tag a condition in os_unix.c as unreachable.
FossilOrigin-Name: 151844ad5451295104f18f4823d2fdaf041f22bc09099f1fa3f90898aafa7ea5
2025-08-02 17:37:59 +00:00
stephan
8c30f16a2e Fiddle: move the About button into the main toolbar. Extend the About text with some info which only shows up (or is only hidden) when terminal mode is available.
FossilOrigin-Name: da524d6c61330fb004dade810c5ad84bb6d37625786c1d0fd473593f2448d904
2025-08-02 15:04:50 +00:00
stephan
f681a9a7d8 Fiddle: make the toolbar visible in terminal mode and hide non-terminal-mode options when in terminal mode. Move the terminal/split-view toggle button into the toolbar. Improve the view-switching handling.
FossilOrigin-Name: 711bf423d213a2c468c32a48c0b09927cdfdffce36e5e4a3b35a32bfa055ff82
2025-08-02 14:50:01 +00:00
stephan
380ef6006b Fiddle: move the About button into the header bar and get it working together with the optional jquery.terminal console mode.
FossilOrigin-Name: 9639382c5478115df7c1584c14a52c176fe747df73078419be4ab276374a704b
2025-08-02 13:21:07 +00:00
stephan
a0e569d5ba Fiddle: add an about/info/help view and a button to toggle it. Change the color schema to a more conventional black/white. Force imported databases out of WAL mode, which doesn't work in fiddle.
FossilOrigin-Name: 27d1d0100c0cb6e5c0c576be0f99209bb905f302008d8c257039adf8c5402f7d
2025-08-02 12:06:37 +00:00
drh
46c7568db5 Ensure that stack space allocated for a flexible array has the correct
alignment.  Fix to [d4307a0d43f42e96] to for some compilers
(DeveloperStudio) and platforms (Sparc).

FossilOrigin-Name: 1cccea0508f5c8b8ff751f407873713adc33f8642dcb6cdd495fd2d72ebcbdd3
2025-07-31 12:25:23 +00:00
stephan
210b182b79 Generic JS doc touchups. No functional changes.
FossilOrigin-Name: cc5f126ea4fa4a1abf183c95d151a7e9bd151b90c5c581d3be56db23bbe05a19
2025-07-31 09:54:09 +00:00
drh
1e687a4187 On MacOS, when increasing the size of files on FAT filesystems from 0 to
1 byte in order to preserve their inode numbers, be sure to fsync() the file.

FossilOrigin-Name: 727efa8559852012cf3381baf5fcb1da198ff27d8856ce7b813920b99367dee5
2025-07-31 09:45:20 +00:00