Commit Graph

2463 Commits

Author SHA1 Message Date
drh
947bd8091b Make sure dot-lock is fully enabled when SQLITE_ENABLE_LOCKING_STYLE is
disabled.  Fix compiler warnings when SQLITE_ENABLE_LOCKING_STYLE is
disabled. (CVS 5976)

FossilOrigin-Name: 4697249fcc6041ba7d2fb89589c855a8bec71eb2
2008-12-04 12:34:15 +00:00
drh
715ff30e27 Reorganize the proxy-locking method in os_unix.c. Additional cleanup. (CVS 5971)
FossilOrigin-Name: 31f6090e22b54d657afc8c23171d000d47850205
2008-12-03 22:32:44 +00:00
drh
9b35ea62c7 Continuing to refactor os_unix.c. This is an incremental check-in. (CVS 5967)
FossilOrigin-Name: c13df0311ef4f6a510f42105293f7c53c323fda8
2008-11-29 02:20:26 +00:00
drh
c5053fb922 Add 19 new assert() statements in btree.c that attempt to detect writing to
a cache page which is not writeable. (CVS 5964)

FossilOrigin-Name: f9c7359065829b016d8cd04304c02509c254fe05
2008-11-27 02:22:10 +00:00
pweilbacher
5a1841a18c expected error message has trailing space (CVS 5963)
FossilOrigin-Name: 165bc2d7658e14eda8b375329e4286dc4d048f3a
2008-11-26 20:09:14 +00:00
drh
a9bce108be Fix the test condition for the test cases added to prevent regressions of
ticket #3508. (CVS 5957)

FossilOrigin-Name: 4e94aa3bedc6dba003a2a4ecbba9c11c465eab4f
2008-11-26 13:44:30 +00:00
danielk1977
36e20936f6 Fix an obscure memory leak that can follow an IO error. (CVS 5956)
FossilOrigin-Name: 8271229c66c72c344ad7afb901b88d9cdaaa6f43
2008-11-26 07:40:30 +00:00
shane
481e9f2089 Added test case to in4.test to try and duplicate crash reported on the mailing list. (CVS 5951)
FossilOrigin-Name: 8502fba37bb13c019252d0a65973a78982ec44aa
2008-11-24 15:32:00 +00:00
drh
17d46fc7f1 Make sure the error message handler is able to deal with NULL expression
spans. Ticket #3508. (CVS 5949)

FossilOrigin-Name: ce36b6474a62f0a5b8d82968ca9a171f7143ae31
2008-11-22 18:28:50 +00:00
drh
107886abe8 Factor out and simplify the canonical pathname logic in the VxWorks OS
interface. (CVS 5943)

FossilOrigin-Name: adb0aafaa6b1ea06541f653a2559f099fb1b2795
2008-11-21 22:21:50 +00:00
danielk1977
f730075312 Fix a segfault that can be caused by an INSTEAD OF trigger on a view that includes an expression of the form "table.column" in the select list. (CVS 5940)
FossilOrigin-Name: 88a09dbb4b54be4010aae767157a1e2002237909
2008-11-21 16:22:18 +00:00
danielk1977
956f4319be Fix an assert() failure that can occur after an OOM error. (CVS 5939)
FossilOrigin-Name: 4c765758c18d7aeffe6e1cf658d2847f9460a956
2008-11-21 09:43:20 +00:00
danielk1977
b247c21c15 Fix the problems demonstrated in tkt35xx.test in a different way to (5936). (CVS 5938)
FossilOrigin-Name: ddf980a50127a9de35edeca5549f4b51e3f733e6
2008-11-21 09:09:01 +00:00
danielk1977
3e168ebec2 Add another test case to tkt35xx.test showing that a statement rollback can also trigger the problem. (CVS 5937)
FossilOrigin-Name: 74c08b8dd9577d1997b4bc8147beed786150f22b
2008-11-21 08:50:50 +00:00
drh
c047b9f74d On a ROLLBACK, if there page cache entries which are dirty but not in the
rollback journal, make sure they get reinitialized in the btree layer. (CVS 5936)

FossilOrigin-Name: faded96f36229ee85039276db693391d0f10648c
2008-11-21 03:23:43 +00:00
aswift
aebf413d9a Added support for proxy file locking style
Added pragma support for controlling proxy file locking
Added file control access to last errno and proxy locking
Added support for TMPDIR environment variable
Extended unit tests to cover new proxy locking pragmas and file control features (CVS 5934)

FossilOrigin-Name: b9bc36d3d5e35821ef69c0881a84c0afed253c9e
2008-11-21 00:10:35 +00:00
drh
1e9db16c55 Force the corruptC.test script to use file format 1. (CVS 5930)
FossilOrigin-Name: deadc2548d1e43cbbfe3af049cc5f59ee55bda46
2008-11-19 18:43:07 +00:00
drh
1feb7dd391 Update the SECURE_DELETE code to track the latest changes in the pager. (CVS 5928)
FossilOrigin-Name: e058f509374e98e48eafeba2f1dadff9633d1190
2008-11-19 18:30:29 +00:00
drh
b232c23297 Add an alternative application-defined pcache implementation and add test
cases to permutations.test to invoke it.  Added the SQLITE_CONFIG_GETPCACHE
method to sqlite3_config(). (CVS 5920)

FossilOrigin-Name: 16f1e6ec2ad92f68c0079a0c2b5ca08a3b4af816
2008-11-19 01:20:26 +00:00
shane
dcc50b74e6 Fixed several more crashes due to corrupt db files. Added corruptC.test to soak.test. (CVS 5905)
FossilOrigin-Name: 9b7a52e952c81e50611e04d2d79003b0ddc57ee5
2008-11-13 18:29:50 +00:00
shane
ec21707dd7 Fixed typo in tkt3472.test that prevented the test from running. (CVS 5903)
FossilOrigin-Name: 428a5479200dc24e2ee9b4a85ef6caadacbdbbd7
2008-11-13 18:02:51 +00:00
danielk1977
ac8d7b35fa Minor changes to get memsys5 compiling and its tests passing. Ticket #3495. (CVS 5901)
FossilOrigin-Name: 96453ca16e90bc0c0cbfb75b3e39899f56d6ea66
2008-11-13 16:21:50 +00:00
danielk1977
0d0654119f Avoid some buffer overreads detected by valgrind while running corruptC.test. (CVS 5898)
FossilOrigin-Name: faa6bd7b615837c920b5b3b027115caa2f56ec15
2008-11-12 18:21:36 +00:00
danielk1977
ef988b47a4 In corruptC.test, explicitly set "PRAGMA auto_vacuum = 0". (CVS 5895)
FossilOrigin-Name: b6563af8f9517760c2346a820e241b0517a10fe0
2008-11-12 14:22:25 +00:00
drh
0d7f4fc4b0 Omit the threadOverrideEachOthersLocks tests for builds that non-unix
or non-threadsafe. (CVS 5893)

FossilOrigin-Name: ab418656dbf3d2e055b2462a155d90863fef6582
2008-11-12 14:07:51 +00:00
danielk1977
ab396298c4 Modify a failing test case in corruptC.test. The test case was failing only because the integrity_check was returning a slightly different error message than expected. (CVS 5891)
FossilOrigin-Name: 0953f300f8e8b2bed79ef3189a1cb29f058f388b
2008-11-12 11:57:41 +00:00
danielk1977
259a455f71 Make sure affinities and implicit collation sequences are correctly used by comparison expressions in the select-list or having clause of an aggregate query. Ticket #3493. (CVS 5889)
FossilOrigin-Name: b8ceaa00500f29bbbd0cc5aec71a6ffa91ae6b43
2008-11-12 08:07:12 +00:00
shane
0af3f8935f Fixed a few more crashes when dealing with corrupt db files. (CVS 5888)
FossilOrigin-Name: f8bb34e40917e55696376d2def932a41ad43d0ae
2008-11-12 04:55:34 +00:00
shane
34ac18daf5 Fixed crash during an UPDATE when free cell size is corrupt. (CVS 5887)
FossilOrigin-Name: ec18667e2d2826a27f2c052ba3790ab5b8cf0bc4
2008-11-11 22:18:20 +00:00
shane
826d5b7e1c Prevent a crash during an UPDATE when the cell offset is corrupt. (CVS 5886)
FossilOrigin-Name: 99d4172ed6825c7efb6cbb28eb00d98323a13954
2008-11-11 20:51:50 +00:00
danielk1977
41a6a61d94 Change the way threadsOverrideEachOthersLocks() works to avoid trying to write-lock a (potentially) read-only files. Also, assume that on non-linux systems threads do override each others locks. Ticket #3472. (CVS 5883)
FossilOrigin-Name: 8ecae0943b06102fe22133db0dcaf58ecbd39545
2008-11-11 18:34:35 +00:00
drh
a78c22c433 Cleanup in flattenSubquery. Add OOM tests for flattenSubquery. Fix issues
with OOM errors causes problems for flattenSubquery.  Ticket #3485. (CVS 5882)

FossilOrigin-Name: ea5f4baa041aed934600f0f96b84afb92a14bc47
2008-11-11 18:28:58 +00:00
shane
5780ebdf79 Fixed crash in integrity_check with corrupt content offset size in page header. (CVS 5881)
FossilOrigin-Name: 0659a666ff0a9fc81ee4df3c35e535164c79e588
2008-11-11 17:36:30 +00:00
drh
753cc1077b When an OOM error occurs while resizing an sqlite_value object, make sure
the value of the object is set to NULL.  Ticket #3488. (CVS 5877)

FossilOrigin-Name: 7b9c9b35fffb233e76148182426199d51243fba7
2008-11-11 00:21:30 +00:00
shane
c782f69abb Updated comment in source. Ticket #3453. (CVS 5874)
FossilOrigin-Name: 83caa22087bcaa184eff559971262e4d7eecd0e0
2008-11-10 19:24:38 +00:00
shane
c8330f4b1d Add check for ifcapable autovacuum to vacuum2-3.3 test. Ticket #3435. (CVS 5873)
FossilOrigin-Name: fc36f2fc45b2d319ef0be97e1af1748d3e862690
2008-11-10 18:20:16 +00:00
shane
2479de3a20 Removed a few more small parts of memsys6 code, including some config and test code for it; (CVS 5872)
FossilOrigin-Name: a11241d6fbc9e0408d5adc73d494b85124d2d609
2008-11-10 18:05:35 +00:00
drh
bbf695d6ea Prevent buffer overruns when converting malformed UTF16 to UTF8. Ticket #3482. (CVS 5869)
FossilOrigin-Name: 3f657e88767f60d305dd6151e7aa54363341d052
2008-11-07 03:29:33 +00:00
drh
1735fa8892 Fix a bug in the CAST operator associated with the column cache. (CVS 5866)
FossilOrigin-Name: 1b6a5140446da896f69fddc8d1ea076815bb45e3
2008-11-06 15:33:03 +00:00
drh
ad4a4b8047 The COMMIT command now works even if there are pending queries, as long
as the pending queries are reading and not writing the database. (CVS 5864)

FossilOrigin-Name: 51f04aaff2803487933b9dfcf39f27a249f18a98
2008-11-05 16:37:34 +00:00
danielk1977
5f6d0268fb Add test cases for sqlite3_db_mutex(). (CVS 5862)
FossilOrigin-Name: f818e8e5cb20c51922d0b5424f17649e0692f273
2008-11-04 14:55:47 +00:00
drh
c46f52034f Avoid a segfault when OOM on a simple EXPLAIN query. Ticket #3478. (CVS 5860)
FossilOrigin-Name: acf26cc0f77b3a308d86f6dc02ecda66a4b12fd0
2008-11-04 14:25:06 +00:00
drh
3e0a3c9df4 Test cases to verify that COMMIT and ROLLBACK return SQLITE_BUSY when
there are active statements. (CVS 5858)

FossilOrigin-Name: cedfa214e4e979ab04a30f558f767d46862151de
2008-11-03 21:40:00 +00:00
danielk1977
e435975093 Modify an assert() statement to fix #3473. No other code changes. (CVS 5856)
FossilOrigin-Name: aca6b260c0dd1a1515b70f3567a0653b6bcdeea2
2008-11-03 09:39:45 +00:00
danielk1977
3072c5ea11 Fix a bug reported on the mailing list triggered by the pattern "SELECT <col>, (SELECT ... FROM tbl WHERE rowid > <col>) FROM ...". (CVS 5855)
FossilOrigin-Name: 6c918c4eb9362ebfdbe0486515679102b2862970
2008-11-03 09:06:05 +00:00
shane
2d16fb1d34 Test that single byte corruptions in increasingly larger quantities are handled gracefully. (CVS 5854)
FossilOrigin-Name: c73d915923e393f72e1c0897526a20527db2e03c
2008-10-31 13:57:40 +00:00
drh
1c0dc8256b Fix a faulty assert() in the merge implementation of the UNION operator.
Ticket #3467. (CVS 5852)

FossilOrigin-Name: cd1662e964d9c071a41038676c5a6ef2c990f1ac
2008-10-30 22:13:23 +00:00
danielk1977
f150c9de55 Fix a crash that can follow a malloc failure in sqlite3ValueFromExpr(). Ticket #3468. (CVS 5851)
FossilOrigin-Name: 0996783b1b7e6dda166565071cbd19f23e7edbbc
2008-10-30 17:21:12 +00:00
drh
99dfe5eb47 Add the sqlite3_extended_errcode() interface. Change to return
SQLITE_BUSY instead of SQLITE_ERROR when a COMMIT is attempted and one
or more queries are still pending. (CVS 5850)

FossilOrigin-Name: 4c6a90a16627b1664bf7f15ab40b440b3bd60b48
2008-10-30 15:03:15 +00:00
danielk1977
281d8bd3ac If a hot-journal file is detected but the application does not have the required read/write permissions, return SQLITE_CANTOPEN. Prior to this change, SQLITE_BUSY was returned. Ticket #3457. (CVS 5849)
FossilOrigin-Name: dc5308c7629abe6a3bad21489c8e97087c264e5a
2008-10-29 07:01:56 +00:00
danielk1977
52bd7912af If an SQLITE_DELETE authorization callback returns SQLITE_IGNORE, proceed with the delete operation but disable the truncate optimization. (CVS 5845)
FossilOrigin-Name: 65a2e131732399f0f14f982eb0689482fdb87b6c
2008-10-27 15:34:32 +00:00
danielk1977
c7af484b4b Make sqlite3_count_changes() and total_changes() work with "DELETE FROM <table-name>". (CVS 5844)
FossilOrigin-Name: e68e4282adb9003aa297d033aeb5d9cadee215cd
2008-10-27 13:59:33 +00:00
drh
31daa63f3e Disable the result-set alias cache when on conditional code branches.
Ticket #3461.  The column cache and result set alias cache mechanisms are
prone to this kind of error and need to be refactored.  This check-in should
be considered a temporary fix in advance of a more general redesign of the
whole mechanism. (CVS 5841)

FossilOrigin-Name: 1fa3bbd8220ce073e91935ea362b6f5d5d6d2859
2008-10-25 15:03:20 +00:00
danielk1977
a2f8c24ca3 Add file tkt3461.test with a few examples of bug #3461. Because these tests currently fail they are disabled for now. (CVS 5840)
FossilOrigin-Name: f2cc159159278201809022706c28bc53b6c3c859
2008-10-25 09:34:59 +00:00
danielk1977
f96a3778f9 Fix a bug in pragma table_info. Column default values specified as negative numbers (col DEFAULT -1) were being reported as NULL by the pragma. (CVS 5839)
FossilOrigin-Name: 0e448bc6096c7ee3b21dbd22dc4ca9470ae7ba31
2008-10-23 05:45:07 +00:00
shane
3ed4e64cd8 Test cases for ticket #3442. (CVS 5835)
FossilOrigin-Name: a8bb5acf708c8f7e52d3f67b85094116386f10fa
2008-10-22 16:04:42 +00:00
danielk1977
d207d8084e Fix an assert() failure that can occur following a malloc() failure. Ticket #3455. (CVS 5834)
FossilOrigin-Name: e0d3aa75b4fa0e706185a3058b5962916e30d066
2008-10-22 10:45:37 +00:00
danielk1977
b3175389c7 Add "pragma journal_mode=memory". Change the way rollback works for in-memory databases so that it reuses the journal_mode=memory code. (CVS 5830)
FossilOrigin-Name: 39ebf01addf9d0867daafd06a38719e725128f9c
2008-10-17 18:51:52 +00:00
danielk1977
ab7bee892b After running speed1.test and speed1p.test, reset the size of the lookaside buffer. Otherwise, subsequent runs of malloc5.test may report an error. Changes to test code only. (CVS 5824)
FossilOrigin-Name: 9283478e69d84aa99b2d4636587c8c0b34e7c4da
2008-10-15 11:43:55 +00:00
danielk1977
4bd3ce69ac Disable the page-cache at the end of pcache2.test. (CVS 5823)
FossilOrigin-Name: 3d2d05b6286e2a22a711e02f37748065b3b7f86e
2008-10-14 19:21:51 +00:00
drh
7cd30bd3d0 Make sure malloc3.test runs even if a CREATE TABLE transaction commits
prior to the last OOM error. (CVS 5820)

FossilOrigin-Name: 603c40e5b47e4798136af5420a1fa1511791a934
2008-10-14 15:54:08 +00:00
drh
104d74c752 Get the load extension tests working on amd64. Needed for test coverage. (CVS 5816)
FossilOrigin-Name: 119b69fba0c27c4c479749360176b6eb69d2e70f
2008-10-13 17:09:11 +00:00
drh
1554262148 In rollback.test, do not check for journal deletion if the journal mode
is not DELETE.  Call show_memstats after each test module in all.test
and quick.test. (CVS 5814)

FossilOrigin-Name: df2c28dc7310510bada292a2e8c1be073803858c
2008-10-13 14:16:11 +00:00
danielk1977
d0ffa1e815 If sqlite3_column_value() is called to obtain a value with the MEM_Static flag set, clear it and set the MEM_Ephem flag before returning. Otherwise, if the value is passed to sqlite3_bind_value() or sqlite3_result_value(), sqlite may attempt to use the buffer after the statement has been finalized. This is not always valid, as MEM_Static only guarantees that a MEM.z buffer will be valid for the lifetime of the owner statement, not that it is actually a static buffer. (CVS 5812)
FossilOrigin-Name: b055bfc4e5268d8a66d6a4f5e8aec1285fe4b8e7
2008-10-13 10:37:49 +00:00
shane
eec556d3b7 Added SQLITE_OMIT_DEPRECATED compile time option to leave out deprecated functions. Updated test scripts to skip tests of deprecated functions if they are compiled out. (CVS 5808)
FossilOrigin-Name: ba3711acee6f4659bbf133a23d8f9f37e14d0f38
2008-10-12 00:27:53 +00:00
drh
8867e38aab Fix a OOM segfault in the BETWEEN operator parsing - discovered while
using SQLITE_OMIT_LOOKASIDE. Add SQLITE_OMIT_LOOKASIDE to test_config.c and
bypass lookaside.test when defined. (CVS 5803)

FossilOrigin-Name: 2a21d52c651ba113c472b6686dcf8ba009924305
2008-10-11 17:06:04 +00:00
danielk1977
435f29d6eb Add "nolookaside" case to permutations.test. (CVS 5802)
FossilOrigin-Name: 56fb7a22864774fcbd8cd00195359dc0f223ec8b
2008-10-11 17:04:04 +00:00
shane
49ffdbf47e Further simplifications of the code for the LIMIT clause on an UPDATE or DELETE. Added a few test cases to wherelimit.test. (CVS 5797)
FossilOrigin-Name: 282c6a46b25f4e4278fd4c8b0b1cde1de28d8f51
2008-10-10 18:25:45 +00:00
danielk1977
50af3e1d2d Change 'pragma foreign_key_list' to return some extra information. (CVS 5795)
FossilOrigin-Name: 3bb33cf59da49f13201c0226e964cda067a4e780
2008-10-10 17:47:21 +00:00
drh
1b67f3caf2 Simplify the symbol hash table to use only a single key class. Other
changes to improve code coverage. (CVS 5794)

FossilOrigin-Name: ff50a8a7e5a15fac192939ff3206fa18d1c5a6dd
2008-10-10 17:41:28 +00:00
shane
468327f16a Added mallocJ.test to test allocation failure handling of the new LIMIT/OFFSET support for UPDATE/DELETE. (CVS 5790)
FossilOrigin-Name: 5375b348b12a4ae149472c84d6f05a78a5542a21
2008-10-10 13:34:29 +00:00
shane
8a7389f276 Initial test cases for the new LIMIT/OFFSET support for DELETE/UPDATE. (CVS 5789)
FossilOrigin-Name: d9f5e15ca00d4d54dc395926e4c9171f1d24982a
2008-10-10 06:01:59 +00:00
danielk1977
510f96590b Fix an assert() failure that can occur if the user attempts to set an into an integer primary key column to a text value in a table that has a BEFORE UPDATE trigger. (CVS 5787)
FossilOrigin-Name: c2cf9d60d6626844193b008a37e4417aa0a0f323
2008-10-09 18:48:30 +00:00
drh
da81eab599 Add a test to verify the sqlite3_column_name() interface returns the
correct value when the query is of the form: "SELECT rowid,* FROM...".
Ticket #3429. (CVS 5785)

FossilOrigin-Name: e90d5a5515f7096e247e6059cf77f8089ed90b2c
2008-10-09 15:56:45 +00:00
drh
073e7b1ca3 Minor cleanup of the new "status" command on the TCL bindings. (CVS 5783)
FossilOrigin-Name: ec01bd72ee875df179c680c1a40304d2f807fe38
2008-10-09 14:45:25 +00:00
danielk1977
be51a65dbc After an OP_NullRow is executed on a cursor, cause any subsequent OP_Next or OP_Prev to behave as if there were no more rows to traverse. Ticket #3424. (CVS 5782)
FossilOrigin-Name: af679f6170b346fe61df7dae963b2a2853e62a62
2008-10-08 17:58:48 +00:00
drh
d1d384888b Add the experimental sqlite3_stmt_status() interface. (CVS 5781)
FossilOrigin-Name: de473efb35ffdf9a8222a70a84dfd7d3198c87c1
2008-10-07 23:46:38 +00:00
drh
18472fa7b8 Remove the SQLITE_MUTEX_APPDEF compile-time option. The SQLITE_THREADSAFE=0
option always removes all mutex code.  For application-defined mutexes only,
use SQLITE_THREADSAFE=1 with SQLITE_MUTEX_NOOP=1.  Ticket #3421. (CVS 5779)

FossilOrigin-Name: 02a12eb1cfe9307c66556105a1a99d657cc01ab5
2008-10-07 15:25:48 +00:00
danielk1977
3d9cf5177f Fix a recently introduced test script bug causing rollback.test to throw an exception when run using the "onefile" variation. (CVS 5778)
FossilOrigin-Name: 7d55ec374d62c6d3d588949b96e194920083fe4e
2008-10-07 15:00:08 +00:00
danielk1977
c56774e234 Fix a problem with hot-journal rollback. SQLITE_CANTOPEN was being returned if the hot-journal file contained a pointer to a master journal file that did not exist. (CVS 5775)
FossilOrigin-Name: 22d1feb9b20b8fd9c86066b94e4220cf8929b043
2008-10-07 11:51:20 +00:00
danielk1977
b1c685b0c8 Allow INDEXED BY and NOT INDEXED to be used in UPDATE and DELETE statements. (CVS 5772)
FossilOrigin-Name: 83a7e446b2d4846a6f92bd831a2adaa265f5a786
2008-10-06 16:18:39 +00:00
drh
6ef7f85801 Add a test script to verify that ticket #3419 stays fixed. (CVS 5771)
FossilOrigin-Name: c3cf54a1b6bbaaeab4cab701c6cbbed02695facc
2008-10-06 15:31:13 +00:00
danielk1977
de89c4cc17 Add a test to indexedby.test to check that automatic indexes (sqlite_autoindex_xxx) can be used with the INDEXED BY syntax. (CVS 5767)
FossilOrigin-Name: bb51c34506b3353506b6f3566fbe2a10d02e8ebc
2008-10-06 11:29:49 +00:00
danielk1977
85574e31cb Allow INDEXED BY and NOT INDEXED clauses in SELECT statements. (CVS 5766)
FossilOrigin-Name: 98ca5580f5acd2e7b3ce512520ec0527f221505e
2008-10-06 05:32:18 +00:00
danielk1977
98c408289c Modifications to bind.test to account for different values of SQLITE_MAX_VARIABLE_NUMBER. Ticket #3409. (CVS 5765)
FossilOrigin-Name: 1a91f3fd58608e258b60305d1d18c3d07d2e9c46
2008-10-03 09:10:45 +00:00
danielk1977
740ed546fc Change one of the test cases in incrblob2.test to avoid allocating a 10MB block of heap memory. (CVS 5764)
FossilOrigin-Name: 83b7dd737a16555b9eb4ad9faacac3d705b0a90e
2008-10-03 08:44:54 +00:00
danielk1977
a8b3018da4 Fix for sqlite3_blob_write(): If either 3rd or 4th argument is less than zero, return SQLITE_ERROR. H17879. (CVS 5762)
FossilOrigin-Name: f6074c0b9b5ba51d131509dba2aec80d0fcf3b7e
2008-10-02 14:49:01 +00:00
danielk1977
41a05b7bee Optimize queries that contain "WHERE rowid IN (x, y, z...)" by using an intkey btree to store the (x, y, z...) set instead of an index btree. (CVS 5760)
FossilOrigin-Name: 803a1736d56b3c07b8ad38715fe0e39196ecc507
2008-10-02 13:50:55 +00:00
drh
0368072905 Adjust the memory usage bounds on the memsubsys1.test script so that
it works on amd64. (CVS 5759)

FossilOrigin-Name: aabde23fe19bd95371fdebdde66ac553dfd53f8e
2008-10-01 13:55:50 +00:00
danielk1977
2d60549926 Fix a bug in where.c where a non-temp register was being incorrectly deallocated. Ticket #3408. (CVS 5758)
FossilOrigin-Name: 59d2e89e2181c26b18eac68ccc80ea3018f70a5e
2008-10-01 08:43:03 +00:00
drh
798fadd14c A few minor changes to test scripts so that they work on linux-amd64. (CVS 5752)
FossilOrigin-Name: 78d075ff38d96cc58659a7097dec0e49402aa960
2008-09-30 00:31:38 +00:00
danielk1977
47dd228e60 Do not run vacuum.test as part of the "exclusive" permutation test. (CVS 5749)
FossilOrigin-Name: 2fb15ae9e9af716a5684a21826814bc4c332a596
2008-09-29 14:27:41 +00:00
danielk1977
7aad2983c9 Update shared_err.test to work with (5668) (return SQLITE_CORRUPT if rollback fails). (CVS 5748)
FossilOrigin-Name: 292acaf7c4e68b532cc8d1763e02aa79d90ea20c
2008-09-29 14:12:56 +00:00
danielk1977
71d5d2cd49 Instead of storing a pointer to the parent page in the MemPage structure, have each B-Tree cursor keep track of the ancestry of the current page. (CVS 5747)
FossilOrigin-Name: 40425e93421286cca1965d7a5769084526210c7a
2008-09-29 11:49:47 +00:00
drh
04335886a1 Add the "truncate" journal mode which commits transactions by truncating the
rollback journal file to zero length and not calling fsync(). (CVS 5745)

FossilOrigin-Name: 7c561f2e9264de676c1028943f6c3d06542fd802
2008-09-26 21:08:08 +00:00
danielk1977
e5dd389698 On windows, avoid running those tests in exclusive.test that require the journal file to be externally accessed while SQLite is holding it open. This doesn't work on windows. (CVS 5742)
FossilOrigin-Name: 5debf12fa46520946ac5da44c03448fffbc9940c
2008-09-24 14:03:43 +00:00
danielk1977
0afae93fa4 Fix some function declarations (change "int foo()" to "int foo(void)"). Ticket #3399. (CVS 5740)
FossilOrigin-Name: 0fb98c35353d8c0a8d669bbe45fe84e3a5060621
2008-09-24 09:12:46 +00:00
danielk1977
98c21903bd Always transform error code SQLITE_IOERR_NOMEM to SQLITE_NOMEM before returning. This was already happening in most places. (CVS 5738)
FossilOrigin-Name: 046ef07261d520c9399bd8cdfdfd5281956b7a27
2008-09-23 16:41:29 +00:00
danielk1977
77eb5bb6f7 Fix a memory leak that can follow a malloc failure in sqlite3_initialize. (CVS 5731)
FossilOrigin-Name: 118dc0ba082dd9abba5602dafc86bd56e756db86
2008-09-22 17:22:19 +00:00
drh
695ba06f23 Do not run the async tests if the async module is not installed. (CVS 5722)
FossilOrigin-Name: 4de71a4e2f59d302156e10efcb288efa23e18598
2008-09-18 18:18:29 +00:00
danielk1977
b11bcfde08 Changes to test script nan.test to work on symbian. (CVS 5718)
FossilOrigin-Name: 0889b22a2949160c3f2d06beaa05a867b4c228b3
2008-09-18 11:30:12 +00:00
danielk1977
3e37f5df5b Changes to test script io.test to work on symbian. (CVS 5717)
FossilOrigin-Name: 2b41c4959da2ef5a882a658e85ee34d07d31f379
2008-09-18 11:18:41 +00:00
danielk1977
89bae3ed7a Changes to test scripts to support running on symbian. (CVS 5714)
FossilOrigin-Name: 6ef34e9d3118965781c69011deaede1ebbb19b12
2008-09-17 16:14:10 +00:00
drh
d176611b44 Fix for tickets #3378 and #3381 that preserves the aliasing optimization.
And yet, this fix feels uncomfortable.  Seeking an alternative... (CVS 5712)

FossilOrigin-Name: f8b759f1977915c314be874840ebf18e6bc69b57
2008-09-17 00:13:12 +00:00
drh
f44ed02790 Add test cases for ticket #3378 and #3381. Add a temporary hack to get those
to problems fixed.  The hack causes failures in alias.test, but those are much
less serious than the aforementioned tickets.  This is a stop-gap until we can
figure out a proper fix. (CVS 5711)

FossilOrigin-Name: a67da9dd2ff6acc163de4ce2b836b03e3f159a88
2008-09-16 18:02:47 +00:00
danielk1977
181ddaa184 Use (file nativename (pwd)) instead of just (pwd) to find the name of the current directory to pass to "PRAGMA temp_store_directory" in pragma.test. This helps the test pass on non-unix systems. (CVS 5709)
FossilOrigin-Name: 50feaa3707f4f61202bc855802ab2e405365d801
2008-09-16 15:50:11 +00:00
drh
ec8d24279b Add test script selectC.test which demonstrates ticket #3381. (CVS 5708)
FossilOrigin-Name: 3847faff55d4bd7574785c3b18d5c95e687c7598
2008-09-16 15:09:53 +00:00
danielk1977
fab1127bd1 If the xAccess() call used by "PRAGMA temp_store_directory = /new/path/" to determine if the supplied directory is writable returns an error, assume the directory is not writable. (CVS 5707)
FossilOrigin-Name: e8418588f2c23487cefda702849d4546202fd8ec
2008-09-16 14:38:02 +00:00
drh
5a70d286f5 Add test case for ticket #3376. (CVS 5705)
FossilOrigin-Name: c64260579d353df3eae8c355b082b8206bc6185b
2008-09-16 11:58:20 +00:00
drh
b5774cfa8f Adjust the page recycling algorithm so that the number of pages allocated
to each connection does not exceed its cache_size limit. (CVS 5701)

FossilOrigin-Name: 3bc221b940565133ae8d95f59b3b120e57df0124
2008-09-15 15:36:57 +00:00
danielk1977
4ff6202642 Fix the async.test test script so that it invokes (finish_test) even if the asynchronous backend is not included in the build (and no tests are run). (CVS 5700)
FossilOrigin-Name: 5c954b40ecb71203b1013c23cdac54ff83484b0a
2008-09-15 14:47:21 +00:00
danielk1977
78a906552d Fix the shared_err.test script so that it works if the device supports SQLITE_IOCAP_SAFEAPPEND. (CVS 5699)
FossilOrigin-Name: 38e5ea070a38fe1656e0f5c3024f28ce67eae725
2008-09-15 14:42:38 +00:00
drh
f018cc2ef0 Fix issues with bizarrely quoted column names. Tickets #3370, #3371,
and #3372. (CVS 5696)

FossilOrigin-Name: ced6bbd228b4a324ddb9c5ff15fd027811c8806a
2008-09-13 01:20:14 +00:00
drh
8578611b95 Fix the NEAR connector in FTS3 so that it can take ranges in excess of 9.
The maximum range is now 32767. (CVS 5695)

FossilOrigin-Name: 8e9b9553115c42dae38cad0612d98d9a0c453a5c
2008-09-12 18:25:30 +00:00
danielk1977
755339ec0f Add a case to permutations.test to run tests with the IOCAP_SAFEAPPEND property set. (CVS 5693)
FossilOrigin-Name: 80bdaafa77ec5c967f633eaaf5ee6f493a6e5a56
2008-09-12 10:22:40 +00:00
danielk1977
540cf6a192 Add a couple of (fconfigure) commands to configure the incremental blob channels used by test file incrblob.test. This is required so that the tests work on windows and other platforms that have a default -translation mode other than 'lf'. (CVS 5692)
FossilOrigin-Name: 753caa20ca50bc42d747d934ccc61438790e7f32
2008-09-11 11:27:59 +00:00
danielk1977
67fd7a9a98 Fix some trivial cases where database corruption was causing an error code other than SQLITE_CORRUPT to be returned. (CVS 5690)
FossilOrigin-Name: 89fda074f6b4959c32f1083badba3c73cffb4995
2008-09-10 17:53:35 +00:00
danielk1977
9f580ad886 Fix for handling database files corrupted in such a was as to make a b-tree page a direct or indirect descendant of itself. (CVS 5689)
FossilOrigin-Name: 93545861a70c190d67b0d1effdd8fe038d28811c
2008-09-10 14:45:57 +00:00
danielk1977
38816ecf99 Avoid deleting a file while it is still open in corrupt2.test. Not all platforms support this. (CVS 5687)
FossilOrigin-Name: 099adfd31167a78d803e2992e5f50cf4e292dd43
2008-09-10 11:28:37 +00:00
danielk1977
f8b10a855e Fix some test script details so that the test suite runs with an SQLITE_DEFAULT_AUTOVACUUM=2 build. (CVS 5686)
FossilOrigin-Name: 300a64b725a111ee66e38de099314f03b064c6eb
2008-09-10 10:57:27 +00:00
danielk1977
f2fb044bca Add fuzz3.test. For testing the library's response to corrupted database files. (CVS 5685)
FossilOrigin-Name: 7fd4dd95791974b0ef6cf30a186b32df25ee2211
2008-09-09 18:28:06 +00:00
drh
e3602be8fd Calling sqlite3_create_function with nArg==(-1) does not override prior
calls on the same function name with nArg>=0.  Ticket #3345.  Add the
new -argcount option to the "function" method in the TCL interface. (CVS 5684)

FossilOrigin-Name: 5aa5b8044a14f59559c1839dc0799b0d2f990809
2008-09-09 12:31:33 +00:00
danielk1977
ff9b2e75b4 If the 'rootpage' column of the sqlite_master table contains a NULL value, return SQLITE_CORRUPT to the caller. (CVS 5681)
FossilOrigin-Name: a7b7b126e9e9b0cd2d68643d8dff321cf41ce2ee
2008-09-08 09:06:18 +00:00
danielk1977
fdd8e5bab8 Deallocate a temp register allocated by codeEqualityTerm() in where.c. If it is not deallocated, its value may be reused by the column-cache mechanism. However, by the time it is used, the value may have been clobbered by a sub-routine that also uses the same temp register. Fix for #3357. (CVS 5679)
FossilOrigin-Name: 7c0f638ef3d7ff9156f07d6fb01448453ffcf5ac
2008-09-06 14:19:11 +00:00
danielk1977
f7cbfae96a Change pcache.test so that it works if sqlite is configured to create auto-vacuum databases by default. (CVS 5678)
FossilOrigin-Name: 55e677569ec131c388841f6f453291f737738076
2008-09-05 05:29:08 +00:00
danielk1977
518002e4ba Fix a problem in btree.c preventing an OOM error from being propagated up to the caller. (CVS 5677)
FossilOrigin-Name: 0b8ee83f2ebadab099ccd6490f6995949dafdd6f
2008-09-05 05:02:46 +00:00
drh
cc91e7f83e Make the default threading mode multithread (-nomutex) in the TCL interface. (CVS 5670)
FossilOrigin-Name: d9e826942673ad048d611c014bfbee39ab5535c8
2008-09-03 01:08:00 +00:00
drh
039963ad33 Add support for SQLITE_OPEN_FULLMUTEX. (CVS 5669)
FossilOrigin-Name: f2f361a5e2fb81fb0f99e83ecf8bae9a750723b1
2008-09-03 00:43:15 +00:00
drh
78f82d1e6c Continuing work on adding full support for the SQLITE_OMIT_WSD
compile-time option. (CVS 5658)

FossilOrigin-Name: ef26ea5c46d3915d206f8ff7f82a24f4c8955f1f
2008-09-02 00:52:52 +00:00
drh
588a9a1a1c Defer deleting Table objects associated with flattened subqueries until
all code has been generated, in case some expression node still references
the Table object.  Ticket #3346. (CVS 5650)

FossilOrigin-Name: d04d70336727a0db959c672e6c22cdaa0505dce5
2008-09-01 15:52:10 +00:00
drh
5393b651c6 Run permutation subtests in sorted order. (CVS 5646)
FossilOrigin-Name: 4cd1bdf3ce8077e10dcd8ae4fe2df0dd9bb0f56b
2008-08-30 16:07:03 +00:00
danielk1977
c1def3e0af Add some code to permutations.test to make sure no test file modifies the shared-cache setting. (CVS 5645)
FossilOrigin-Name: 8565b7c66525dc7808a2a266deb1a0d995c99917
2008-08-30 13:25:10 +00:00
danielk1977
3dbb0572d7 Make sure thread003.test waits for all spawned threads to finish before continuing. (CVS 5644)
FossilOrigin-Name: 87c7e82f54cd446721d553d5c48ca2571b063669
2008-08-30 09:10:16 +00:00
danielk1977
7a1d17f1d7 Modify tclsqlite.test so that it works reliably with tcl 8.5.4. (CVS 5640)
FossilOrigin-Name: 790d329f5d18d361a5d6d34f46c269f8b4057cd9
2008-08-29 15:54:56 +00:00
danielk1977
34c61e68ad In permutations.test, disable tests that depend on soft-heap-limit functionality when running the memsubsys2 variant. It disables the soft-heap-limit. (CVS 5639)
FossilOrigin-Name: 047c7bdb9f37462c462071334f1cb9d3400917db
2008-08-29 12:00:20 +00:00
danielk1977
062d4cb0ae If a page is made eligible for recycling when more than the configured maximum number of pages are allocated, free it immediately instead of adding it to the LRU list. (CVS 5638)
FossilOrigin-Name: 4b12922dcb4547bf3a7276d0542b2e1d12ad338d
2008-08-29 09:10:02 +00:00
drh
8b213899e8 Avoid reevaluating WHERE and ORDER BY expressions that alias terms in the
result set.  Ticket #3343.  Note that aliased GROUP BY expressions are still
evaluated twice. (CVS 5637)

FossilOrigin-Name: ab0292caa5887cc1bdc0e8c9d3f3502b83975440
2008-08-29 02:14:02 +00:00
danielk1977
3fb120cb9d Fix ioerr5.test so that it works with the new pcache module. (CVS 5636)
FossilOrigin-Name: 83e6a75e7d70b4b01f0892924d7a8a49d5ef6bf2
2008-08-28 18:35:34 +00:00
drh
570f5c7d70 Partial fix for a bug in recovery from xStress failures in pcache. (CVS 5635)
FossilOrigin-Name: 44193b92770062271711570d8532fa5af5f5da54
2008-08-28 17:46:18 +00:00
danielk1977
81fa193a66 Avoid using (clock seconds) in thread003.test. It is not available if testfixture is linked to tcl 8.5. (CVS 5634)
FossilOrigin-Name: b606263d0868aed267bcec623b9fe4d142099145
2008-08-28 13:55:10 +00:00
danielk1977
f599a1994c Enable the disabled asserts added by (5629). Add extra tests to thread003.test. And the required modifications to pcache.c. (CVS 5631)
FossilOrigin-Name: 473c09fac22ed2f56ea86150a60b9f0f2263c889
2008-08-28 10:21:16 +00:00
danielk1977
51d2d03636 Fix a threads/mutex problem in pcache.c. (CVS 5630)
FossilOrigin-Name: 1928f15b78eee0fbf0a8ecdbbdd38dbbde2942b8
2008-08-28 08:31:48 +00:00
danielk1977
59633aeec2 If any error occurs during sqlite3_open(), move the database handle into "sick" state. When in the sick state the user can use sqlite3_errcode() and sqlite3_errmsg(), but not much else. (CVS 5628)
FossilOrigin-Name: ce9c74eaab459ddde213c828e821940f5d6cb354
2008-08-27 19:01:57 +00:00
drh
255538e947 Add the trans2.test script designed to stress statement rollback and
no-write optimizations on large transactions with a small cache. (CVS 5627)

FossilOrigin-Name: 39c34e2238c27b2a2f4f0b896126ccbd299114c5
2008-08-27 18:56:36 +00:00
danielk1977
468c82bc50 Modifications to malloc5.test to account for the fact that sqlite3_release_memory() no longer reclaims dirty pages. (CVS 5625)
FossilOrigin-Name: b01c65b065c62e3dd71e88866a953668b5e2f25f
2008-08-27 16:38:56 +00:00
drh
8af6906348 Clear the $result variable prior to using it in corrupt2.test. (CVS 5624)
FossilOrigin-Name: 12f2d24f88e55d170dd7750e7904ff14e84e820e
2008-08-27 16:14:20 +00:00
drh
426c854102 Fix an issue with the permutation test script. (CVS 5619)
FossilOrigin-Name: 2e12aa3e078c0da9e418ff1f25a08f05cd03c07d
2008-08-26 23:08:04 +00:00
drh
7426f864ae All the page_size pragma to change the page size on a new :memory: database,
but not a vacuumed :memory: database.  Ticket #3335 (CVS 5617)

FossilOrigin-Name: 226a9056783247679fcf442e10807a1f2707f463
2008-08-26 21:07:26 +00:00
danielk1977
d491e1bfd1 Simplify the pcache module by only recycling clean pages from 'other' caches. This commit causes errors in test files ioerr5.test and malloc5.test because they test recycling dirty pages from other caches. (CVS 5615)
FossilOrigin-Name: 9e511e161bcb077450d31fca5dd20c2557f103b3
2008-08-26 18:05:48 +00:00
drh
229cf702f0 Do not flatten subqueries where the subquery has a LIMIT and the outer
query has a WHERE clause.  Ticket #3334. (CVS 5613)

FossilOrigin-Name: 4995a1d1c9530be9ce647d338169620cd95a72eb
2008-08-26 12:56:14 +00:00
drh
df81a25abe Fix obscure permutation test problems. (CVS 5611)
FossilOrigin-Name: aa92a1bec3d6bbcc59680ba13fed51ada9249d4c
2008-08-25 19:09:01 +00:00
drh
0a846f96ef Fix bug in the premutation testing that was causing many permutations from
begin skipped.  There are now 16 errors reported by the permutation test. (CVS 5610)

FossilOrigin-Name: 4ad096bda1fc5c7b66f71ff5b32a4085c9a40574
2008-08-25 17:23:29 +00:00
drh
f436620e3f Additional coverage testing in the new name resolver module. (CVS 5608)
FossilOrigin-Name: 0d61960afd35721d6d07acd75288c20d2cd6fda1
2008-08-25 12:14:08 +00:00
danielk1977
8c20014a0a If the sector size is greater than the database page size, SQLite journals all pages that lie within a sector before writing to any of them. This change ensure that a journal sync does not occur halfway through journalling the set of pages that belong to a single sector. (CVS 5605)
FossilOrigin-Name: 16f612d61e00938f29ecae4ebfe598be7a8709a8
2008-08-25 07:12:28 +00:00
danielk1977
06249db141 Do not incorrectly detect corruption when an auto-vacuum database is converted to a non-auto-vacuum database within a vacuum. Ticket #3332. (CVS 5603)
FossilOrigin-Name: cb869946d68f2abbd1322fababbe4aa74a4e08aa
2008-08-23 16:17:55 +00:00
drh
9d8b3072ce Enhanced test coverage. (CVS 5598)
FossilOrigin-Name: cc36b4e016a1f519ca81d591de3a551ee8aa6813
2008-08-22 16:29:51 +00:00
danielk1977
a858aa2e8c When recycling a page, try to find one that does not require a call to xSync() on the journal file. Also simplify some of the mutex related things in pcache. (CVS 5597)
FossilOrigin-Name: 93dbc5427bebaa0b3d726731027caad3f70611c7
2008-08-22 16:22:17 +00:00
pweilbacher
e7c8a5c75d fix some tests to take the right branch on OS/2 (hope I got the Tcl syntax right) (CVS 5593)
FossilOrigin-Name: 10e62d4700c99faf07140a8204d3cd81481206ac
2008-08-22 13:57:39 +00:00
drh
f388dc19e6 Add test case to verify that Ticket #3301 was fixed by (5569) (CVS 5590)
FossilOrigin-Name: 73b260686264a31f43211efb235e4e0121115a50
2008-08-22 12:46:45 +00:00
drh
2a5d825ea2 Allow the WHERE clause in an UPDATE or DELETE against a view with an
INSTEAD OF trigger to refer to the view by name.  Ticket #3298. (CVS 5589)

FossilOrigin-Name: 7360e5d1f37ed6672f336b625b3c90d060e0a020
2008-08-22 12:30:52 +00:00
aswift
831045dd33 Deferring file descriptor closing to avoid trashing locks when directly manipulating sqlite db file contents (causes errors on AFP testing) (CVS 5587)
FossilOrigin-Name: e28a2870b49509502529892ff8ddb9fcf3a27173
2008-08-22 00:25:52 +00:00
danielk1977
801880f66c Fix soft-heap-limit related test suite failures. (CVS 5582)
FossilOrigin-Name: 2091d9a5260b1d7e27ff5ca93e60dae1e3b12081
2008-08-21 15:54:01 +00:00
drh
f0209f7410 Make sure "rowid" columns in views are named correctly. Ticket #3308. (CVS 5580)
FossilOrigin-Name: 8593218c7c8016fbdbcc223db951751eaba9c0dd
2008-08-21 14:54:28 +00:00
drh
74073b6da8 Add test cases to verify that ticket #3314 has been fixed. (CVS 5579)
FossilOrigin-Name: b46267ff07f9b967bb7aee16b6d9dd8d0bd23f0c
2008-08-21 14:24:29 +00:00
drh
6a012f04d5 Reinsert an SCopy operation that was removed in (5523) because coverage
testing indicated that it was dead code.  Ticket #3324 shows that the
code was not as dead as we thought it was. (CVS 5578)

FossilOrigin-Name: 6855711595b58d4b6fbaf9480720b788904d0e2d
2008-08-21 14:15:59 +00:00
danielk1977
67e3da7ad4 Fix the functionality associated with sqlite3_release_memory() and sqlite3_soft_heap_limit(). It is automatically disabled if the SQLITE_CONFIG_PAGECACHE option is used. (CVS 5576)
FossilOrigin-Name: d025866b09352b32a6d35b97144eaad2fafb7165
2008-08-21 12:19:44 +00:00
drh
7d10d5a6e1 Refactor the name resolution procedures in the code generator. (CVS 5569)
FossilOrigin-Name: daf730d1defa78fb8b80a78f9108ac35a13e09f6
2008-08-20 16:35:10 +00:00
danielk1977
260d8a6aec When a "pragma main.table_info(...)" is issued, consider only tables from the main database, not the temp db. Ticket #3320. (CVS 5568)
FossilOrigin-Name: d0cfbbbaeef7b8ce9f73c6cd58888989a2df5b1f
2008-08-20 16:34:24 +00:00
danielk1977
8c0a791a58 Add the pcache module from the experimental branch. Also change things so that most of the built-in SQL functions are kept in single static hash-table, rather than creating and populating a separate hash table for each open database connection. (CVS 5566)
FossilOrigin-Name: cb494e10d71852024647aaa254203579ad438ea9
2008-08-20 14:49:23 +00:00
drh
2b300d5d6f Do not flatten the right term of a LEFT join. Ticket #3300. (CVS 5565)
FossilOrigin-Name: 8947c72f93d0b79c8061a3bfd5ab595edfb155a5
2008-08-14 00:19:48 +00:00
drh
ec1fc80ca3 A partial fix for ticket #3292. This fixes the original problem but there
are other similar problems lurking in the code still. (CVS 5561)

FossilOrigin-Name: 055f173ab1b6fb657bf817faa3a37335d8fa60d5
2008-08-13 14:07:40 +00:00
drh
ec444fc163 Make sure the lookaside test script saturates the lookaside buffer even
when SQLITE_DEBUG is off.  Ticket #3289 (CVS 5560)

FossilOrigin-Name: d6aacc5dc7c06f97fb5faa3d85a8f2d8ab0dd554
2008-08-12 15:48:25 +00:00
drh
93ed56d9ea Revise the initialization and shutdown logic so that it no longer keeps
a recursive mutex allocated for the whole interval but instead releases
the mutex as soon as possible.  Do not reset status values upon initialization. (CVS 5559)

FossilOrigin-Name: 697fe7a3167c22a3232ce154e9d47cf75af613c4
2008-08-12 15:21:11 +00:00
drh
c456e57af7 Do not allow indexing of any table whose name begins with "sqlite_".
Ticket #3284.  Improve handling of databases with malformed schemas -
just in case somebody has actually indexed a system table. (CVS 5553)

FossilOrigin-Name: 0e1d8d14a153483e65bd0246d23db2b823a122d1
2008-08-11 18:44:58 +00:00
drh
e50135e26d Add SQLITE_STATUS_PAGECACHE_SIZE and SQLITE_STATUS_SCRATCH_SIZE. (CVS 5537)
FossilOrigin-Name: c4e9b824062ba82a8db01cd82e3e681de1940208
2008-08-05 17:53:22 +00:00
drh
e9d1c720ee Separate verbs of sqlite3_config() and sqlite3_db_config() into their
own namespaces.  Allow SQLITE3_DBCONFIG_LOOKASIDE to specific an external
memory buffer. (CVS 5536)

FossilOrigin-Name: 5dd865da5e787c10ef4c9e96647724bfab9dea01
2008-08-04 20:13:26 +00:00
danielk1977
de3e41e304 Fix (make test) with SQLITE_OMIT_COMPOUND_SELECT. Ticket #3235. (CVS 5530)
FossilOrigin-Name: 9ca975c8fdeaae7d5af8fe62e097d8d251362cfe
2008-08-04 03:51:24 +00:00
drh
e6a6464895 Test scripts revised to work when auto_vacuum defaults on. (CVS 5528)
FossilOrigin-Name: e63186b0b6defce9ce16b3c334887c1f5a0bfcf0
2008-08-02 20:09:36 +00:00
drh
701bb3b4f0 Additional coverage testing. Fix a segfault following OOM in
sqltie3_load_extension(). (CVS 5523)

FossilOrigin-Name: f1e44eb323f05495cbae25113aebcc50d16b40df
2008-08-02 03:50:39 +00:00
drh
c890fec362 Bring test coverage up to 99%. (CVS 5522)
FossilOrigin-Name: 2cd6bae80984126023bcf479e5f3db5eaa5c4134
2008-08-01 20:10:08 +00:00
drh
4cfb22f798 Fix problems in test scripts. Add new test cases to improve test coverage. (CVS 5521)
FossilOrigin-Name: b65f493c7519e8a5ee632a395b57d45269741dda
2008-08-01 18:47:01 +00:00
danielk1977
987a00e8b5 Also test that setting sqlite3_vtab.zErrMsg works from within the xRename method. (CVS 5520)
FossilOrigin-Name: 4f4a9ccae7d25b9856d1203f6b289d552c2b425e
2008-08-01 17:51:47 +00:00
danielk1977
3e3a84d32a Test that virtual table methods xBestIndex, xOpen, xFilter, xNext, xColumn, xRowid, xUpdate, xSync and xBegin can all return error messages using the sqlite3_vtab.zErrMsg variable. (CVS 5519)
FossilOrigin-Name: 007359b770f225877880b11f4c5d97bb548e38ca
2008-08-01 17:37:40 +00:00
drh
6480aad473 Test cases for sqlite3_db_config() and sqlite3_db_status(). (CVS 5518)
FossilOrigin-Name: 6a6b94302acdfe6404b04bff1cc8d16c1ef69df9
2008-08-01 16:31:14 +00:00
drh
e2a7c6e04f Add a permutation test case for running all OOM tests with lookaside
disabled. (CVS 5517)

FossilOrigin-Name: 3f70e03ae83d374f5f69770bd7a4b279584f7090
2008-08-01 15:06:30 +00:00
drh
129ed69ea2 Update the memsubsys1 test script to take into account the buffer size
changes of the previous check-in. (CVS 5513)

FossilOrigin-Name: d43ff7bb8fc59c54b85658aaeb3dd088a324276f
2008-07-31 17:20:58 +00:00
shane
8225f5ac55 Omit calls to test_get_table_printf() if SQLITE_OMIT_GET_TABLE defined. (CVS 5509)
FossilOrigin-Name: 524a4075ddaecb07469da717e8afebc91240616e
2008-07-31 02:05:04 +00:00
shane
2a5fc4d6f5 Omit calls to test_destructor16() if SQLITE_OMIT_UTF16 defined. (CVS 5508)
FossilOrigin-Name: 2d5cec53c2f31875d198d81ac4fd54e7066ea0ff
2008-07-31 01:47:11 +00:00
drh
5462624dc4 When opening a zero-size database on unix, write one byte into the file before
interrogating the inode number.  This works around issues with msdos
filesystems mounted on OS-X.  Ticket #3260. (CVS 5504)

FossilOrigin-Name: a480a8845fb3b49967de0790b30e6250c824b9be
2008-07-30 17:28:04 +00:00
drh
61669b3824 Implicit string->numeric conversion should go to an integer value when
possible.  Ticket #3257. (CVS 5502)

FossilOrigin-Name: da0e4bff30a77f72ae283406b547401c2ebb42c5
2008-07-30 13:27:10 +00:00
drh
d63bd75987 Make sure everything is deallocated before calling sqlite3_shutdown().
Ticket #3259. (CVS 5501)

FossilOrigin-Name: 4a6ee88697ddc28e0c7df1954d1526de18191827
2008-07-30 13:15:46 +00:00
shess
7fdb522caf Backport http://www.sqlite.org/cvstrac/chngview?cn=5489 from fts3.
Re-used prepared statement from fts2 cursor. (CVS 5499)

FossilOrigin-Name: 02870ed21dae2601a656b2f30c3ca0041e9cb60f
2008-07-29 20:38:17 +00:00
shess
9eb7c2ad83 Add some simple tests to make sure that the different fulltextFilter
query paths are being exercised. (CVS 5498)

FossilOrigin-Name: ae96d960e6e31315d25c7e5c3fb8363ed1b35350
2008-07-29 20:24:46 +00:00
drh
5f4bcf15d1 Enhancements to the pagecache malloc test configuration. Changes to the
speed test scripts to use the new test enhancements. (CVS 5494)

FossilOrigin-Name: 0ce39c21f32958ae53c00dc8bbf8cdd453f2d90e
2008-07-29 14:29:06 +00:00
danielk1977
003c1ffa15 Add a missing "finish_test" to the end of misc5.test. (CVS 5491)
FossilOrigin-Name: 89216b166924e831dd6264dd60f8da42cef7deee
2008-07-29 10:26:45 +00:00
drh
633e6d57d9 Implement the "lookaside" memory allocation cache. Use of this cache makes
the speed1.test script run about 15% faster.  Added new interfaces to
control the cache. (CVS 5488)

FossilOrigin-Name: e48f9697e9fea339e150ddc32940760027dd07d9
2008-07-28 19:34:53 +00:00
danielk1977
161546c7e5 Fix a case where database corruption was causing an invalid reference. (CVS 5484)
FossilOrigin-Name: 7aecabacf924ad8c1f9f4e707d0c56e433e3a434
2008-07-26 18:26:10 +00:00
drh
ec424a5be6 Add the capability to track the maximum depth of the LALR(1) parser stack
so that critical applications can check to see if they are getting close
to limits. (CVS 5481)

FossilOrigin-Name: ef0250f3dc769a4acd534f31fa06d90922d4145b
2008-07-25 15:39:03 +00:00
drh
1bb14aca96 Fix the corrupt7 tests to track changes in the integrity check error message. (CVS 5480)
FossilOrigin-Name: 22177dac2e3cd9acafe7fcc71674a675fdd098ff
2008-07-25 14:53:17 +00:00
drh
ebf1b467f7 Increase limits on memsubsys1 tests to accomodate the larger structure
sizes on 64-bit platforms. (CVS 5479)

FossilOrigin-Name: f7720f1bfcc6dcdd60002520e10f545a6f0eb126
2008-07-25 13:39:08 +00:00