Commit Graph

18887 Commits

Author SHA1 Message Date
dan fdcd9d4e6c Prevent users from creating zipfile() virtual tables without an argument.
FossilOrigin-Name: 81fdbe0cc5a360f818078d47a5888d0a29d555927da279a9a0213702d74ef09a
2018-01-30 14:07:55 +00:00
dan ea4125bbef Add unix-only tests to check that the "unzip" program can unpack archives
generated by the zipfile extension.

FossilOrigin-Name: 438c5c5237a801ae78809bf324bb9251fb50250addfc1f8e36659442b0e26ab6
2018-01-29 19:47:32 +00:00
dan f8c4b99a02 Add aggregate function zipfile() to the zipfile extension. For composing new
zip archives in memory.

FossilOrigin-Name: e364eeac76a8225146b37d801bc6cabe03e9abede5a1412ebe9d94a32d8838cc
2018-01-29 18:41:07 +00:00
dan 8433e7166b Update the omit-left-join optimization so that it works in some cases when the
RHS is subject to a UNIQUE but not NOT NULL constraint.

FossilOrigin-Name: 88411a402b29f19d69e0d06d9099eabb98c238ddb7c07ce110236316f008753e
2018-01-29 17:08:52 +00:00
dan 26e731cc88 Ensure the "unique-not-null" flag is set for automatic indexes on columns
declared with "col UNIQUE NOT NULL" (where the NOT NULL comes after the
UNIQUE).

FossilOrigin-Name: 8767f7b880f2e4112f75f0b6ef7be3f50ab1ae20e103e7d03d8bfe77e6c79438
2018-01-29 16:22:39 +00:00
dan a07aa8d397 Fix missing header comments and other code issues in zipfile.c.
FossilOrigin-Name: 6ea8ba312c38365d3e28cfb2a367d729dd2751d1d853843eea0e18126777a320
2018-01-27 18:55:18 +00:00
dan 26333ee3ca If a zipfile virtual table is created with no argument - "CREATE VIRTUAL TABLE
zzz USING zipfile()" - accumulate data in memory. Support "SELECT
zipfile_blob(z) FROM zzz LIMIT 1" to retrieve a zip archive image.

FossilOrigin-Name: e63185edfe0c316aa60c1fa085d032425ecc7db54536dfa5a977772eaf3c240e
2018-01-27 16:29:59 +00:00
drh 1822ebf9b1 Changes to avoid a harmless UB warning from clang.
FossilOrigin-Name: 19f5c1400054df10688ab448e7e23afef97cab4a7c7a3e411f7527509b515dd8
2018-01-27 14:25:27 +00:00
drh c9f3db33d5 New test case for ticket [ec32177c99ccac2b1] that works without the STAT4.
FossilOrigin-Name: 5259d4847f2b73f26b2385f9d8cff8fe0cabc54b4deab8477c87c8d1bb5535b1
2018-01-27 13:55:56 +00:00
drh 33f10207aa Proposed fix for the query planner problem of ticket
[ec32177c99ccac2b1].

FossilOrigin-Name: eef8cbef3c49e6331301a8f3f8a5fd12090b1e99e68487c2d405e53ef771f688
2018-01-27 05:40:10 +00:00
drh c86caa58cd Fix compiler warnings in zipfile.c.
FossilOrigin-Name: bed610d99b5322ee209b06966c0086e8c55f8a82be8d7693cfdeb4d728679721
2018-01-27 03:26:10 +00:00
drh 33f763d154 Fix the query planner so that it takes into account dependencies in the
arguments to table-valued functions in subexpressions in the WHERE clause.
Fix for ticket [80177f0c226ff54f6dd].

FossilOrigin-Name: 7daa687340e475972d6849f84fe1419a1f5700934f53fd80656849adc73d6d04
2018-01-26 22:41:59 +00:00
dan 8005d60587 If the argument to table function zipfile() is a blob (not text), assume that
it contains a zip file image to interpret, not the name of a file on disk.

FossilOrigin-Name: 029ebcd30cb261d949f7587ac54c23d7479796b6716fd4ca7512361b8f32de3e
2018-01-26 18:59:25 +00:00
drh 4eb57ceffc Improve text-to-integer conversion in boundary cases. The
sqlite3Atoi64() function always returns the minimum or maximum integer
if the magnitude of the text value is too large.  Trailing whitespace is
now ignored.

FossilOrigin-Name: ace0644a1a2a42a3ea42d44f00a31915b8a7e56c9ba90f90a6c02001f89f9c86
2018-01-26 18:37:34 +00:00
dan 8558ef2e19 Reorganize zipfile.c code to make it easier to add support for in-memory zip
archive processing.

FossilOrigin-Name: 30b9258294e3028ef4ea467e332e013995509544e9a23c8bbf5168772a7e895d
2018-01-25 20:50:46 +00:00
drh cad42838d7 Slightly smaller and faster implementation of OP_If and OP_IfNot.
FossilOrigin-Name: 6ab42934e2c4957b5d8927bf4434a9db07ab6078987a6a2d25f35cc468d21203
2018-01-25 01:20:29 +00:00
drh 9f8952390a When unpacking a sorter record, do so from right to left instead of left to
right, since by starting with the right-most column, the work done by
OP_Column opcodes is reduced.

FossilOrigin-Name: 8055e4f42446ceb5bcf752bbf41a73289c3ca759c56c9f779edc3d7f202b7881
2018-01-24 20:42:42 +00:00
dan 1a0e5b37b2 Reorganize spellfix.c to make it easier to edit automatically (e.g. using a
script). No changes to functionality.

FossilOrigin-Name: 090a64faaac579c6ed1cddb02d14e7089468a4aeaeec11e78d461790bcb6eb0a
2018-01-24 18:28:39 +00:00
drh da6bc6792f Rearrange fields of the BtCursor object so that it is smaller and requires less
initialization, for a small performance improvement.

FossilOrigin-Name: 0ddf5292cc0411ec6fcb7399ecf2904c899e0488404d3f65490fbe1db15efdf4
2018-01-24 16:04:21 +00:00
drh fe875027d7 Add the normalize.c extension.
FossilOrigin-Name: 16ebe558d2f0982f630c39b6c1b00d14d27011d454cced213f17c26491a2c06e
2018-01-24 15:07:37 +00:00
drh 31a13548f8 Merge changes from trunk.
FossilOrigin-Name: 6ef3de810d54563c227045b16197b8011ce285ea867261946f93b2de55344f29
2018-01-24 15:02:53 +00:00
drh a8519d79b9 Interchange the numeric codes for CURSOR_VALID and CURSOR_INVALID to obtain
a small size decrease and performance increase.

FossilOrigin-Name: e0f192ea6dda4fa0b243d58c8ce41932519141bcae0689a90318b4f866f54edd
2018-01-24 14:40:01 +00:00
drh 4d6d872c49 Adjust the fts3rank.test module so that it works on big-endian systems
(hopefully - I don't have a big-endian machine to test the change on.)

FossilOrigin-Name: e4766cabdf64d8e998048ae43154466fc9c3fad0b86102a42b65122abfcbbe55
2018-01-24 14:39:18 +00:00
drh a87f8ce262 Improved error message output when the btreeinfo.c extension is run in
a connection that lacks sqlite_dbpage support.

FossilOrigin-Name: 461b0b81b2acedb1b9ca520657518d6778417c375aeb58c41ead840b75a6d985
2018-01-24 13:15:56 +00:00
drh b9f4799b55 Prevent a harmless unused variable warning when compiling with
SQLITE_OMIT_TRACE.

FossilOrigin-Name: 61a44961b5811c993ae8d4f820a21a0ee739fe5e88cbfe5e4190e0091912ca19
2018-01-24 12:14:43 +00:00
drh 93117f0c4b Fix a formatting issue in sqlite3_prepare_v3() documentation. No changes
to code.

FossilOrigin-Name: 9e6066de84285252fb8999a8d8e02a46c5bb6c822e4f7421ad3911687357ee5d
2018-01-24 11:29:42 +00:00
drh 9ccc0fd1f9 Fix the sqlite3ext.h header file so that it correctly accesses the
new sqlite3_value_nochange() and sqlite3_vtab_collation() interfaces.

FossilOrigin-Name: 6185d190e250faae0d979a24cb1039c7fce178478ae75df8e4af1d94cd38c18e
2018-01-24 11:25:59 +00:00
dan 0aac5613d9 Update a couple of test scripts so that they work on F2FS file-systems that
support atomic transactions.

FossilOrigin-Name: 49e58e645e0c114c71935a3b7fa4771e8a23e28127efd2efe0f2f18813c8f391
2018-01-24 06:30:10 +00:00
drh 56f1774603 Make the shell functional even if compiled with SQLITE_OMIT_COMPLETE.
Omit the sqlite3_complete() call from the fuzzing interface if it is
compiled with SQLITE_OMIT_COMPLETE.

FossilOrigin-Name: c3e816cca4ddf0967c4c790cdde2345101dde3f2d854e62589f1ac1d7f3c60b8
2018-01-24 01:58:49 +00:00
drh 5347f3c111 Invoke the sqlite3_complete() interface from the fuzzer.
FossilOrigin-Name: 332bf84625d2034c9e1c029aa8243aa34088217e52e34e1f5472217743a31af3
2018-01-24 01:02:23 +00:00
drh 588049cc99 Increase the version number to 3.23.0 for the next development cycle.
FossilOrigin-Name: b58b60b2c0729b73c0ef35bd1a5aa90965d1c01043413ca45b412d8b68f59bce
2018-01-23 20:22:15 +00:00
drh 21d5978422 Remove an unreachable branch from sqlite3SkipAccumulatorLoad().
FossilOrigin-Name: 8b9c8eab60b692e45c55a718d76b70e63040416040696907463692cbf83fb0c5
2018-01-23 19:24:54 +00:00
drh d15046ac08 Work around a problem with GCC on 32-bit machines that cause the CAST
operator to generate a floating-point result for strings that could be
represented as very large integers.

FossilOrigin-Name: 1b02731962c21bb097a88801ece76ff441bf882519a821a246da84f4e2a33455
2018-01-23 17:33:42 +00:00
dan a916b57013 Fix a bug causing spurious "sub-select returns N columns expected 1" errors
in join queries with a term like "(a, b) IN (SELECT ...)" in the WHERE clause.

FossilOrigin-Name: 14dfd96f9bca2df5033b2d894bf63cc8bf450a45ca11df5e3bbb814fdf96b656
2018-01-23 16:38:57 +00:00
drh 61d04974f0 Fix the modification-time setting logic in the fileio.c extension on Windows
so that it works with utf8 filenames.

FossilOrigin-Name: f785b9041556912edbacdbfb3dfc38705058d7c10d874544295c25db54628bc2
2018-01-23 15:26:30 +00:00
dan b8fff29c68 In SQLITE_ENABLE_BATCH_ATOMIC_WRITE builds on F2FS file-systems, invoke
SQLITE_FCNTL_ROLLBACK_ATOMIC_WRITE if an SQLITE_FCNTL_COMMIT_ATOMIC_WRITE call
fails. Also, do not use an atomic transaction to create the initial database.
This is because if an error occurs while writing to the db file, any changes
to the file-size do not seem to be rolled back automatically. The only time
this matters is when the file was 0 bytes in size to start with.

FossilOrigin-Name: b3122db1545aeb48b7c28d480534b4b0fe04e83d5336225714c3cad926e5960e
2018-01-23 14:01:51 +00:00
drh 8d7f163015 Fix comment typos. No changes to code.
FossilOrigin-Name: 8e5e74c66b9cdb348392e3db2d9f32cfa20fcec35bf09d9e1f623e7ad875ec97
2018-01-23 13:30:38 +00:00
mistachkin 176b3a09b2 Skip defining WIN32_LEAN_AND_MEAN when it is already defined.
FossilOrigin-Name: 195f5323df800f7963df2ea251c497c72e4d7ff0b88a70f1fa60f13bb1a9fd3b
2018-01-23 07:11:05 +00:00
drh 7ea3469e53 Slightly faster implementation of the length() SQL function.
FossilOrigin-Name: 9a4199aedb039141a50a68943ef863d7df9637ada318793cce6c12b9d39bcdc5
2018-01-23 04:22:33 +00:00
drh f09ac0b336 Slightly faster function dispatch in the virtual machine by avoiding
unnecessary reinitialization of variables that are already correctly
initialized.

FossilOrigin-Name: edd4e6876cc08ab907bb21f075380de946562d4c56a04923760848b4b11536ac
2018-01-23 03:44:06 +00:00
mistachkin fa3d785580 Simplify one of the compiler warning fixes from the previous check-in.
FossilOrigin-Name: 012d7d49c571207087bbe24af05d639627b96df526bfcb2098a3e975b74d865d
2018-01-23 00:17:27 +00:00
mistachkin b71aa0955b Fix harmless compiler warnings seen with MSVC.
FossilOrigin-Name: 76a11a80e94d1e9c9645e6e348948f3fd508266d4569c85d80a3879862d0a819
2018-01-23 00:05:18 +00:00
drh 138d4f8de2 Version 3.22.0
FossilOrigin-Name: 0c55d179733b46d8d0ba4d88e01a25e10677046ee3da1d5b1581e86726f2171d
2018-01-22 18:45:57 +00:00
drh 8bfe66a9c4 Avoid unnecessary OOM detection warnings in a debugging routine.
FossilOrigin-Name: 395f8ea790e6e295800fa8927f0585b2419b9521ef4fd591d51d2a48db2a90c4
2018-01-22 15:45:12 +00:00
dan 3a9b9b7749 Fix a test case in walro2.test so that it works with encryption extensions
(when each page has a little less usable space available than usual).

FossilOrigin-Name: b79521d255a4aa2a7b4424f3498443f27d329ab5428171ba6b87c987f3ccdfc2
2018-01-22 15:20:59 +00:00
drh 88284b0dc3 On the walro2-X.4.2.2 test case, show the size as part of the test output.
FossilOrigin-Name: ac5091d7f870f1d0659a576723de454d544e5bfa2bdbba307d7c81eb5ab34e3b
2018-01-22 14:49:15 +00:00
dan 2f94935409 Allow the shell to be built from the configure script with
SQLITE_OMIT_VIRTUALTABLE defined.

FossilOrigin-Name: 136bf323e42dc90e1780199a381bcbb084b069eca5c7343ee6fc6e2550831536
2018-01-20 15:48:45 +00:00
dan 1a3a308616 Use a loop to avoid recursion in the heightOfSelect() function.
FossilOrigin-Name: 86de43595cb2ecebd680fe654affcfb9fbcfff6575c893293ae298124a357bfe
2018-01-18 19:00:54 +00:00
dan 5a7da86f5b Check for both zlib.h and -lz before enabling zlib support in the amalgamation
configure script.

FossilOrigin-Name: 8ecd13a1b38e58d4464585c388c1aa27d1f056dba0db239316623e81d3eb5284
2018-01-18 17:46:08 +00:00
drh 80db2d6521 Update the autoconf configure.ac script and Makefile.am templates so that
ZLIB is automatically detected and used.

FossilOrigin-Name: 41bfb6b8d61699d09a7e67d2289149abfbb9ce8e75e6ff8560546cad0d2e3f2b
2018-01-18 17:09:26 +00:00
dan b8a0fb75db Fix sessions module handling of sqlite_stat1 rows with (idx IS NULL).
FossilOrigin-Name: 0e916416331d7948b312a5dd58ac0c145030bb3b47a37dab2636564397249a86
2018-01-18 16:59:52 +00:00
dan cae5b9feac Clarify the handling of the sqlite_stat1 table by legacy versions of the
sessions module.

FossilOrigin-Name: dc7c48cb4126db9e25c73512cc743155293fe1c4c2516f8c84102228695b6e70
2018-01-18 16:56:19 +00:00
dan e3ca3831ba Add comments describing the special sqlite_stat1 handling to sqlite3session.h.
FossilOrigin-Name: 4431a3256f7436e34b3c33edc1f3e53df7eb3c87daec9bac8d038895d93ca7f2
2018-01-18 16:53:41 +00:00
drh 4b3931ef33 Fix to the documentation for sqlite3_trace_v2(). No changes to code.
FossilOrigin-Name: 6fbd0a11a66f8eb4d7820cb49c23bdcb917db98a22c29d76edea1eea6dab0a4e
2018-01-18 16:52:35 +00:00
dan d1cccf19b5 Fix sessions module conflict handling for the sqlite_stat1 table.
FossilOrigin-Name: f05ee74e05c401eb075a1ba65179662a08a5c3d5b55fc81f2acc841e841dd055
2018-01-18 16:42:11 +00:00
dan 1611e5a301 Simplify the sessions preupdate-hook logic for transforming NULL to X'' for
column sqlite_stat1.idx.

FossilOrigin-Name: 089d7cecaaa47db58320b216a111a5e56123d022008be6c81bc0746148bbdb58
2018-01-18 15:06:23 +00:00
drh 3dc9727782 Alternative implementation for the internal sqlite3Pow10() utility for MSVC,
which is more accurate on that platform.

FossilOrigin-Name: 469b96be5350ba2291518280ffe179b87aa7fbe701e2813ef63843922771517a
2018-01-17 21:14:17 +00:00
dan 3739f29807 Fix a problem in the sessions module with logging sqlite_stat1 rows for which
(idx IS NULL) is true.

FossilOrigin-Name: 25bf734be1b3883fccf12ac4d93d50289aa307fb60a52e0e32df12f7ee4edc7a
2018-01-17 20:57:20 +00:00
dan 61c758b53a Fix a problem causing the sessions module to occasionally lose track of rows
with composite primary keys when there are two rows with the same text value
in the leftmost column of the PK.

FossilOrigin-Name: 09aed13678374bf22087cd808808b711dc703b7c18bc8aaf704850611e17f5cd
2018-01-17 17:38:18 +00:00
dan 26893c98d2 Fix main.mk so that testfixture can be built either from the amalgamation or
from individual source files. No changes to code.

FossilOrigin-Name: a8aea925f8fde8f2dc5ff4b744d54aa2bf8916f3ee57f22d77fd1ddb5a35a9cc
2018-01-17 16:11:26 +00:00
drh b968518559 Fix harmless compiler warnings, mostly unused parameters for UDFs in the CLI.
FossilOrigin-Name: bfbeffab7735461acb3773242ba31dae15af9f8b0291c54a6734747bb1b36e66
2018-01-17 13:15:23 +00:00
dan f193937620 Omit the single test from zipfile.test that uses json functionality in
non-SQLITE_ENABLE_JSON1 builds.

FossilOrigin-Name: 6bb2a10fad71bf8cec6bca538db7b00be0d26418ab62b83092d3a6a68d1c0d9f
2018-01-17 12:58:11 +00:00
dan 30fe26c47f Update test file fts5fault6.test to account for test tokenizers implemented in
Tcl returning SQLITE_ERROR instead of SQLITE_NOMEM following an OOM error.

FossilOrigin-Name: c232f6424a858ede44940a927fe4e26ee99c6ab614aa6f63e13ba46e88dbb280
2018-01-17 12:57:07 +00:00
mistachkin 98e2cb8bd1 Simplifications to winOpenSharedMemory in the Win32 VFS.
FossilOrigin-Name: 3e04999dabb87715de46255b1a9b08d5dfa70d140e0a09a37ea2842d71c77caf
2018-01-17 01:40:57 +00:00
mistachkin 5685257b83 Corrections to error code handling in os_win.c, pursuant to walfault.test.
FossilOrigin-Name: 568192228c9578b8ea34c363e10ff28450045cda76248b2f0f89f84b3a57e680
2018-01-17 01:26:05 +00:00
mistachkin 824f28426a Fix duplicate test names in 'walfault.test'.
FossilOrigin-Name: 7274d05ff43fc9872f0e4857ae583689e4a6c429b7fa991dcc29744da3048879
2018-01-17 01:15:08 +00:00
dan 2879952faa Fix a problem causing zipfile to store 0 in place of the CRC32 value for
uncompressed files.

FossilOrigin-Name: ba44724bcca2e87788b7c6d8c5de7fa388360127bd894ee6a171fd66e794fcae
2018-01-16 21:09:00 +00:00
drh 8c9e30ba2f Remove an unused field from the internal definition of the sqlite3_context
object.

FossilOrigin-Name: 948a26b5a64d8a89c4ec7546ec4a4bee36e29e82edda677ca75424e7091325d0
2018-01-16 21:05:10 +00:00
drh 2d9e8c55da Fix compiler warning in the FTS5 test interface.
FossilOrigin-Name: 2ab4e8d5d82ab410c00f048c12555f2f40f9fd8bffda64ccbdd3dfe036727315
2018-01-16 21:00:58 +00:00
drh 4a4532bbb7 Make the new sqlite3_vtab_collation() interface accessible to loadable
extensions.

FossilOrigin-Name: f301db3c2343fd2086bc5b69a17b2d226175584ccd09549ebb2cb603590da487
2018-01-16 20:50:37 +00:00
dan 4bd387495f Fix a test problem causing an error in fts5fault9.test.
FossilOrigin-Name: 8e2048113fc6ed87fc7d5ba470261926aa0bd35474744bb2b99ea596bc468f02
2018-01-16 20:44:00 +00:00
drh eb0b6f364e Remove the unused SQLITE_CANTOPEN_DIRTYWAL result code.
FossilOrigin-Name: 3c786305fc6eaa6856ec6c71fc7969f61de266ba1bea0abf0ae133eb94e54b2d
2018-01-16 20:37:56 +00:00
dan 70bc717c0e Fix a makefile problem causing -DSQLITE_ENABLE_STMTVTAB builds to fail.
FossilOrigin-Name: 7f6e5bdf9021c31e8bde82c224bf53be3c93b79f7bb5c2802c54be8031cf89fb
2018-01-16 20:20:00 +00:00
drh 0ed2fd8a25 Move the ZLIB version announcement in the CLI out of the default banner
and put it in the ".version" command.

FossilOrigin-Name: 231679d6f8c0c3d957c8daa88b0743449b60b47159e114f4bc073a8612a73b2a
2018-01-16 20:05:27 +00:00
mistachkin fff5367c24 Show version of zlib in use when running the shell tool in interactive mode.
FossilOrigin-Name: a8906b527a8f7a2cec88cc3b05c063a2785f0d1d141e148d954fc7440972a484
2018-01-16 19:03:51 +00:00
dan 194a17bbb7 Change a cat in zipfile.c from (z_const Bytef*) to just (Bytef*). This allows the module to build with older versions of zlib.
FossilOrigin-Name: ac9af91d5a2927e71903461e7bbdd2c0168fde9a042853c8bcd4c7ebd0d51e0d
2018-01-16 17:33:09 +00:00
dan 0c2ba13e02 Fix a problem causing an infinite loop or other malfunction in some UPDATE
statements with an OR term in the WHERE clause.

FossilOrigin-Name: feb2c2b6f66b0f45490beb1642d99cdb89fa220e299a8c118929df557c814189
2018-01-16 13:37:43 +00:00
drh ded2d99d73 Disable the ".archive" command tests in shell8.test if the CLI is compiled without
ZLIB support.

FossilOrigin-Name: ce8bfe6c2b87090a2de1e04bc88fcb878597fe1f4ecd5df6d9d588a65601c901
2018-01-16 02:38:35 +00:00
dan 2d620070b9 Fix a problem in the zipfile module causing it to generate incorrect
checksums. Remove the ability to insert compressed data into a zip archive.

FossilOrigin-Name: b0b7d0363acf38c2178e2d3041d8ce2a0de061a51caa64670dbf539ee6d4356b
2018-01-15 19:00:35 +00:00
dan 89fa746941 Fix a zipfile problem with extracting zero length files compressed using
deflate.

FossilOrigin-Name: cf64087224aff1a2fe169d23996d9e5ed8d86459c655eb5d0bace0466a557ec6
2018-01-15 15:49:46 +00:00
drh a9be508a97 Fix an error in the setDeviceCharacteristics() procedure for the
(unsupported) QNX code in os_unix.c.

FossilOrigin-Name: 8151913a3987f4dd2d6efee046727f5fa9b6f11d5d3867ea8f512c03a212ac2b
2018-01-15 14:32:37 +00:00
drh b058d05452 Avoid excess stack usage when a VALUES clause with lots of rows occurs
within a scalar expression.  This fixes a problem discovered by OSSFuzz.

FossilOrigin-Name: a4fa0581ba7cfd45fabe0198f55b3c2c8ee3ecfd2825aeed91116f44e77d760b
2018-01-14 20:12:23 +00:00
drh eb54500419 Fix harmless compiler warnings in zipfile.c.
FossilOrigin-Name: 8f7a592f8c044d75b4615a95e27454100b10c2b26f4cafee97dec23343821130
2018-01-13 23:28:33 +00:00
dan f42884c307 Support UPDATE statements against zipfile virtual tables.
FossilOrigin-Name: f2d2a5df4f29b47212fd2411eae6545087b901a270655640c87ceb472e02a24c
2018-01-13 19:08:24 +00:00
drh cdb60978b9 Fully initialize the Mem object for serial-type 10, in case such a
serial-type is found in a corrupt database file.

FossilOrigin-Name: bd70a07d819a54346cb6c40fab681424c5af0dfb6bf29321a3de9fc99d285376
2018-01-13 14:28:00 +00:00
dan 098728fc9c Fix various problems in test scripts preventing "make test" from passing on
F2FS file-systems with the "atomic-write" feature.

FossilOrigin-Name: 6bedc7435d26c1f21c0d1b3a52daa0169fa5416b690a99347328dcafdcd78740
2018-01-13 14:02:16 +00:00
dan 2483a111db Fix a typo in crash8.test.
FossilOrigin-Name: c3dc7b8d9de94e46fae75fcc96ec68743205e0a2591e14391c394fff203004d1
2018-01-13 14:01:26 +00:00
dan 69aedc8db4 Fix various problems in test scripts preventing "make test" from passing on
F2FS file-systems with the "atomic-write" feature.

FossilOrigin-Name: 56d93d070d6b92d8a5a3fec1b09aae8911116c73d072fc5022f0b51668ed996b
2018-01-13 13:07:49 +00:00
mistachkin 2034353db4 Updates and minor typo fix for the README.
FossilOrigin-Name: bb196fcb677e962db4308c02097968615729a51fe4a1292e468aaf3e4bf522d3
2018-01-13 02:07:16 +00:00
drh 76506cd3a7 Add the new "nochange" APIs to the extension loading mechanism.
FossilOrigin-Name: cd7c42699e73b688dbed29ed5d243d06439d7dbe0ba8c42d8299e04cc0dd4464
2018-01-13 01:53:09 +00:00
drh 9df81a2989 Add the sqlite3_value_nochange() API, usable from within the xUpdate method
of a virtual table to discover whether or not a column was unchanged at the
SQL level.

FossilOrigin-Name: dec3ea4e4e6c4b1761ddc883a29eaa50dcd663ce6199667cc0ff82f7849d4f2a
2018-01-12 23:38:10 +00:00
drh 41fb367a2c Improved comments. Slightly tighter implementation, but no big changes.
FossilOrigin-Name: a1b3f28569f2a8d82b2931527fdfe191b421f3e1ea18ee30e04211e1ad645993
2018-01-12 23:18:38 +00:00
drh ce2fbd1b02 Add the experimental sqlite3_value_nochange() interface usable by xUpdate
methods of virtual tables to see if a column has actually changed values.

FossilOrigin-Name: 8b7be15ece9e2e83959bb0e21e240106fe1077431242c3cc6b81f1baa2382f40
2018-01-12 21:00:14 +00:00
drh 4ec6f3a075 Simplification to the implementation of OP_Insert.
FossilOrigin-Name: 6acbdba59e9df4313a6232d925a70390acdc43dfa380b4fba7bb8bd442d6e728
2018-01-12 19:33:18 +00:00
dan 5871318407 Fix error handling in sqlite3session_diff() when it is invoked for table
"sqlite_stat1".

FossilOrigin-Name: 874285e477dd9bd164e25ddb08b6b80daaa8cfd111b4180ecce59b1ce26f77a5
2018-01-12 19:20:15 +00:00
drh 84ebe2b303 Avoid an unnecessary branch when not using pre-update hooks.
FossilOrigin-Name: ec96707eb359c7e0597ee22e5ae017774366463dffa6bdb06e4438b09549f5c0
2018-01-12 18:46:52 +00:00
drh 3f975373ce Fix obsolete comments. No changes to code.
FossilOrigin-Name: ec39c99bea024ffce9b87bbf3d80087ff772f43f7fb7e238754c364f7db2a17b
2018-01-12 18:03:38 +00:00
dan f3e3dfe96c Include changes made to the sqlite_stat1 table in changesets
generated by the sessions module. sqlite_stat1 entries in such changesets are
ignored by legacy clients.

FossilOrigin-Name: 2064233533edec0308d0212fb08e72fd14c760a1c88452424cae298e9eaf4af8
2018-01-12 17:25:25 +00:00
dan 614efe2b4b Experimental change to include changes made to the sqlite_stat1 table in
changesets generated by the sessions module. sqlite_stat1 entries in such
changesets are ignored by legacy clients.

FossilOrigin-Name: bd46c4429693545eb16db85692fc591ac529796aa746f5f21df1ce4380619320
2018-01-12 16:44:29 +00:00
drh 6ac7303e1a Always use utimes() instead of utimensat() since the latter is not available
even on some recent unix systems.

FossilOrigin-Name: 30ed7a4b6408f0ca921abc4d8b7bb5404fc7708cedcd104b017b361054e7148c
2018-01-12 14:34:45 +00:00
dan f225059b8b Add a test to ensure that the sqlite3changeset_apply() function ignores tables
that do not have the expected primary keys.

FossilOrigin-Name: bf2daf06279e46bc37cc92ad1becec1b12d2aa804a14b101fca8b3a7fdb280c3
2018-01-12 12:02:02 +00:00
drh afd4eef575 Add the sqlite3_vtab_nochange() interface. Test cases are in TH3.
FossilOrigin-Name: a5d09dfaa337fa51d6e702c6aefe58824ab1e7d221c6e79166e2c6f9c7ab1501
2018-01-11 18:15:40 +00:00
dan 66a3a91aa6 Change zipfile to be a WITHOUT ROWID virtual table and table-valued function.
FossilOrigin-Name: 931201f64e04247ed613a0301fcc86c3a337c2ed162c6370a80c67a1dd919e7c
2018-01-11 17:33:48 +00:00
drh 6f390beb7f Add the sqlite3_vtab_nochange() method which virtual table implementations
can use to optimize UPDATEs.

FossilOrigin-Name: d444b1ff39f0a1673a977b8047e1e14a49d461c9934be080d27c2392a830c1c0
2018-01-11 17:04:26 +00:00
dan 5e9bbe1924 Add test cases for running multiple RBU operations within the same process
concurrently.

FossilOrigin-Name: 407b5ed35c178bb0dbc69c8b902652038a0653d55a58a7543f9d4857c6baf3ea
2018-01-11 16:16:03 +00:00
drh e4185bda9a Minor formatting changes in zipfile.c. No logical code differences.
FossilOrigin-Name: 4f68bed3b9a63a349a2a2d7f26609491577e9717034ad86af404cf9eed9d6aaf
2018-01-11 14:50:40 +00:00
drh 24cd20ffa4 Fix typo in comment. No code changes.
FossilOrigin-Name: 2c55571baaae58d6f5b6210cf85d0fa325a9977682bd449e3802191f7a4142de
2018-01-11 13:43:04 +00:00
drh 536c345107 Update the .help screen in the CLI. Make sure the temporary files for
".open" are not deleted too soon.

FossilOrigin-Name: b8d92d8dc239597c6f01a6e572b047f98ce374a8f48257683fa839dde3ec993f
2018-01-11 00:38:39 +00:00
drh 9791313474 Add the built-in edit(VALUE) and edit(VALUE,EDITOR) function to the CLI.
FossilOrigin-Name: ef823c47a0ac4f3b001e6c89c38354b45b5229d872cfc69a29c82e99414b89c8
2018-01-11 00:04:00 +00:00
drh df53b05e3c Add the ".once -e" and ".once -x" commands to the CLI, and the ".excel" command
that is an alias for ".once -x".

FossilOrigin-Name: a6ed5ab9bc9741267fd1207e63b4c49d074291085c7e3f25e9f62a82f916a656
2018-01-10 23:29:42 +00:00
drh 6c9dcc427d Update test cases for the new "usage" for .output.
FossilOrigin-Name: fbf5e43c07e7c012cb39b33a74b3fab9e46ba946c48497fbd990110692125f57
2018-01-10 23:27:30 +00:00
drh 3c484e8c1f Save and restore the output mode when doing ".once -x" or ".excel".
FossilOrigin-Name: f697c164518d36f2a63c87d9f2708d0f9481fad3ded2de61f3f48c393cf7a500
2018-01-10 22:27:21 +00:00
drh a92a01a77e An attempt to get ".once -e" working reliably on Windows.
FossilOrigin-Name: 9b97f9d2c876162139dbd9485fcf68412d1572d9ddc179b08938b8a602e895d6
2018-01-10 22:15:37 +00:00
drh 7f3bf8a9fb Fix a potential SQLITE_MISUSE in the .excel command when no database is open.
FossilOrigin-Name: 9b95ff1abfb8d49bbe5a727f5c917a455e4289b4d69196377dc9294409341d70
2018-01-10 21:50:08 +00:00
drh 13c209330d Add support for the ".excel" command (and ".once -e" and ".once -x") in
the CLI.

FossilOrigin-Name: 23fa7c57c2b204d1ddcc2a939b5271628cf26689ad4ede6976038113095a9801
2018-01-10 21:41:55 +00:00
drh cc9c26a092 Fix a harmless compiler warning in zipfile.c
FossilOrigin-Name: 60c694c1ab26a7a096f17ccea5a93ecda0f9f2113ab5fdc8b17dbffc787724fc
2018-01-10 19:50:40 +00:00
drh d99c7b7bcb Include RTREE in the default CLI build.
FossilOrigin-Name: 6a6a3d495633b906ca31f513c30d31e6daf0f0f105be9ba0a0dc07d201d5b630
2018-01-10 19:15:21 +00:00
drh ca7733b782 Modify the new "--append" option to the .archive so that it takes a filename
argument, the same as "--file".

FossilOrigin-Name: 58e3b07cc8cb5cc915f7d430483bd455b03f14120e0db23286d2e20dbb5391c5
2018-01-10 18:09:20 +00:00
drh e15c5e532a Add the lsmode(MODE) function in the fileio.c extension and use that function
in the .archive implementation.  Add the --append and --dryrun options to
the .archive command and remove the --zip option, making it automatic.

FossilOrigin-Name: 38f28029d16df8489772c27867de8888dd1c26b170861acdc977fd4023939dde
2018-01-10 17:44:03 +00:00
drh 346606494a Fix minor problems with the new ".archive" command changes.
FossilOrigin-Name: 612b30c95f948438016bd11470e9dd114d7bb064418a57e5954a094d2ca77f69
2018-01-10 17:39:54 +00:00
dan 4bfd182939 Return an SQLITE_CONSTRAINT error if an attempt is made to insert duplicate
entries into a zip archive.

FossilOrigin-Name: 1f099b2b45074c89eeff8ff241aa49489c95c2221b25c305fcda670ebf63fb4e
2018-01-10 17:37:58 +00:00
drh 410cad975f In the fileio.c extension, change the filetype(MODE) function into lsmode(MODE).
Use the new lsmode(MODE) function in shell.c.

FossilOrigin-Name: 52d12ba9f33c1f2620776e189c81f3bf991759344ecdd167ea2a6107f0972b9d
2018-01-10 17:19:16 +00:00
drh 634c70fa15 Implement the ".ar --create" command using a single
"REPLACE INTO sqlar SELECT ... FROM fsdir();" statement.  Add the
shell_putsnl() SQL function for providing --verbose output.

FossilOrigin-Name: 28ab930436fea33c79073e84f39d9e381fa60b4702a5dcbfaaed72baeeae8431
2018-01-10 16:50:18 +00:00
dan f2ed70e4de Have the zipfile module automatically append "/" to directory names that do
not already end with such a character. This is required for info-zip
compatibility.

FossilOrigin-Name: 94bc3c60e7d2ec849b90444b06e3057ed645edf3af334f2737252960602868e5
2018-01-10 16:30:40 +00:00
drh 6c237b1fa7 Add the "filetype()" SQL function for interpreting file modes to the
fileio.c extension.

FossilOrigin-Name: 58c0c74c407d93f48930a4964b6cc48f008b522d193a62a559de0e6a319a8bd0
2018-01-10 15:53:06 +00:00
drh a5676c4d2d The ".ar" command deduces whether or not the target file is
a ZIP or SQLAR and does the appropropriate thing.  The "-z" option is omitted.
The "--append" option is added to open auxiliary databases using apndvfs.

FossilOrigin-Name: 430d1a7daa823ae53606b7a158af4e7c16f62ff9b072b90606524e7c3f6131df
2018-01-10 15:17:34 +00:00
drh a82c95b47d Allow the use of ".ar -t" without specifying an archive file or the "-z"
option when the command-line shell is opened on a ZIP archive.

FossilOrigin-Name: 9340a2c145bcb4b38d19276a16264a37341c617f0554d66e1da653f1d9f85163
2018-01-10 14:00:00 +00:00
drh e75d1f5290 Tag an unreachable branch using ALWAYS().
FossilOrigin-Name: c42c734f11c58724f5d8b32cb1c92e274be350028868d6ed045b2cfd274c64e7
2018-01-10 13:58:23 +00:00
drh b376b3d6aa Work on the ".archive" command.
(1) Add the --dryrun option.
(2) Do not require --file when open on a ZIP archive.
(3) Miscellaneous code simplifications.
This is an incremental check-in of work in progress.

FossilOrigin-Name: a2baada429e84dc4b7243173a056e3c8bc042682f7efb01fdf8d2cc452c97e04
2018-01-10 13:11:51 +00:00
dan a688ca5ea9 Fix a problem in os_unix.c causing it to return SQLITE_CANTOPEN instead of
SQLITE_READONLY_RECOVERY.

FossilOrigin-Name: 6a16f554f027ba268276b728588b5eaea837cbed85358a06a2f6da3b70e834ad
2018-01-10 11:56:03 +00:00
drh 5af0698356 Rearrange some routines in shell.c to avoid the need to forward reference a
static function.

FossilOrigin-Name: fd7f51a107806666d5c3a3a7a62528ec3e1fb71c4256f49d57b4dcdac4bf8680
2018-01-10 00:53:55 +00:00
drh 6116ee4eee Compute the correct column name even if the column identifier is the
very last token in the SQL statement.  This fixes a problem introduced
by check-in [0fdf97efe5df745510c6b] and reported by the community during
beta-testing.

FossilOrigin-Name: 36b89d728ff13d395fe0e1db8e7c01263f73dccb278b3ece27f6ef78e909b492
2018-01-10 00:40:06 +00:00
mistachkin dc006e05aa When disconnecting from the 'swarmvtab' extension, close each database prior to invoking the 'openclose' function on it.
FossilOrigin-Name: 3e5647cb6c4553683e24b9cb62548f16c79c4e2ac9e39cf135ea52a623f7cc33
2018-01-09 22:23:42 +00:00
mistachkin 7026bd6753 Fix harmless compiler warnings.
FossilOrigin-Name: 0fb42090cb2c785e044abe273a00da134927db191fea7b0c67ba4028944bce3a
2018-01-09 20:49:33 +00:00
dan 2c4df97591 Return SQLITE_CONSTRAINT if a user attempts to update a zipfile table.
FossilOrigin-Name: 64c9ccf6c5598a68135e78dad128ec070afa49416e1d1f35745a24276e7aeeea
2018-01-09 20:44:04 +00:00
dan 9898c4a0c4 In the os_unix.c implementation of xOpen(), do not return
SQLITE_READONLY_DIRECTORY in cases where the file cannot be opened for reasons
other than a readonly directory, such as the process running out of file
descriptors.

FossilOrigin-Name: fa8b80bb967792de99808712ac03e37ace0f11eb8fbe444aacd3d19184c425ea
2018-01-09 20:34:53 +00:00
dan c48e0271f6 Fix a potential crash in sqlite3expert.c caused by a missing sqlite3_reset()
call.

FossilOrigin-Name: f6355970f04a3c4d85801c806366788139d8d5ad29383ec7faa81e2176ffe987
2018-01-09 18:31:11 +00:00
dan e2d22ffaa3 Fix another -fsanitize issue in new shell code.
FossilOrigin-Name: 6ee7b54c580de0240e0f49a5fd2d11ddcdbcce8a2ae4b249618d0ab2d54b5e5b
2018-01-09 15:57:55 +00:00
drh 4297584d66 Updates to the README.md file for the ext/misc directory. No code changes.
FossilOrigin-Name: 6b3f4349d7156501f05270d494d6002ee03a0860b6e77b46d17effcab027b753
2018-01-09 15:28:25 +00:00
dan 6b046be41a Fix the shell so that it can be built with SQLITE_OMIT_VIRTUALTABLE.
FossilOrigin-Name: 931421a22507a5e1edb46e19cb5b3958ec3904807836ab5bcc7a90f37f476e6a
2018-01-09 15:25:55 +00:00
dan f87ae41f52 Do not attempt to build the code in ext/expert/sqlite3expert.c if
SQLITE_OMIT_VIRTUALTABLE is defined.

FossilOrigin-Name: ba967ad2e38590fe2a51e814a087140089be5e6a06a795a958e70a8a47f6350f
2018-01-09 14:30:49 +00:00
drh 8ee5d0fc05 Attempt to fix the fileio.c extension so that it builds on MinGW-64.
FossilOrigin-Name: a7446d3217d39c96c884fbfb294dd320378255f3bfb34e35d15ba6d7c6698f53
2018-01-09 14:27:58 +00:00
dan 128011a258 Fix a zipfile problem with adding new directories to an archive.
FossilOrigin-Name: 5fed67033c9dd4492bf8cfcf98874284581f448d8cc84fa5470dde239f218375
2018-01-09 10:29:34 +00:00
dan cc234a4b66 Fix a problem in zipfile.c found by -fsanitize.
FossilOrigin-Name: 4fe697fa6c2b45aec60c33eff1ce2ea97b8a2ca124ef0c0059930269d25cdb2e
2018-01-09 07:16:51 +00:00
drh a8691309dd Avoid a compiler warning when building with newer versions of MinGW
FossilOrigin-Name: cba0206a15f30313e16a08634995ebfd5d325d83affb859a215e72509f539b4e
2018-01-09 02:27:13 +00:00
mistachkin 562f0c8e46 Improve portability of compile-time MinGW detection for the command line shell.
FossilOrigin-Name: 4a7236140cb0f40fa846da4673a0d56218def1929d58cf016909ce881a681140
2018-01-09 00:28:24 +00:00
mistachkin 88a1d6b92c Fix harmless compiler warnings.
FossilOrigin-Name: 1adf4e60391326ba699260402c06604ea25b456e903157ecb05017e7ea954fc4
2018-01-09 00:26:39 +00:00
drh 91694dbdd2 Test cases for sqlite3_normalize().
FossilOrigin-Name: 658f42257d56a3562dfa8e55023c6e497f55c565cd751d942de3a9e0cb2fa708
2018-01-08 20:04:57 +00:00
dan 7c15ac1ada Update the zipfile module so that it matches the documentation.
FossilOrigin-Name: 7e7e472fa91a2bad2e521d4d67f176c8eb9edc1a07b283e425ea0fa2b6abba1f
2018-01-08 19:59:59 +00:00
drh d19866bb98 Special handling of the NULL keyword. Sometimes it is a literal, and sometimes
it is a keyword.

FossilOrigin-Name: db5d138e97f22ad4d4d11dbef96df93696ba0e557809066bc263ca3c3898f349
2018-01-08 19:29:28 +00:00
drh ef42481224 Add IN-operator normalizating and the SQLITE_NORMALIZE_CLI compile-time
option for generating a stand-alone program.

FossilOrigin-Name: d77dbb398afa80c1b3373c55f278491e83d5c80ddc22dbc303876bdcbc127df9
2018-01-08 19:18:27 +00:00
dan d4bb7c180b Fix problems in the sqlite3expert.c code revealed by -fsanitize.
FossilOrigin-Name: 7a93dd784bfdbf01927979a61643796e0901d9ac285fe4214677838def93a9a4
2018-01-08 17:34:15 +00:00
dan 4064a4cc58 Add an "ifcapable trace {}" block to a test in fkey1.test that uses SQL
tracing.

FossilOrigin-Name: 7182591d351dde22ed2f6a60521d1d7c10a610d702e79693412efc6938167be0
2018-01-08 17:12:54 +00:00
mistachkin 1bc1e2fb5d Remove a superfluous define from the 'fileio' extension when compiled for Win32.
FossilOrigin-Name: 6dcba6693f064b0e21360c5eab18abe4a1534f6699b5d7b92e60eab6be14c347
2018-01-08 17:09:05 +00:00
dan dcfbff9a86 Fix a malloc/sqlite3_free mismatch in the shell tool code.
FossilOrigin-Name: fe053b2ecdc04b918367fa503bf10292fd7cd84a6929670857b2e9153df4d1f9
2018-01-08 17:05:32 +00:00
drh a41f2855e9 First code for an auxiliary function that will normalize an SQL statement.
FossilOrigin-Name: 84814aac81e54f03430f180926156ab0fc01e22bbce2bb228b698ea0d4a588ea
2018-01-08 16:54:26 +00:00
mistachkin 98dfb2fc08 Fix compilation of 'sqltclsh.exe' for MSVC.
FossilOrigin-Name: abb112d9e1a51c1c2f15d1e5f3dc161c9a947841f69a56715f5f1c62603096b2
2018-01-08 14:24:08 +00:00
drh a5da4ef4ad Avoid the use of utimensat() on older unix platforms.
FossilOrigin-Name: 90cb01d8d6ac12d0b88f2952a75aeefa81ba66f5e4a5377fdd8b9f86aec8e927
2018-01-07 23:28:10 +00:00
drh 03491a1a1a Remove the dependency on test_windirent.h from the generated shell.c file.
FossilOrigin-Name: 0a50c9e3bb0dbdaaec819ac6453276ba287b475ea322918ddda1ab3a1ec4b58b
2018-01-07 21:58:17 +00:00
drh 8682e12190 Modify the sqltclsh startup script to look for a properly formatted
SQLAR at the end of the executable.  Fix the CLI so that it automatically
links against appendvfs and so that the --append command-line option works.

FossilOrigin-Name: 67c4a8c6881e33b830aa27c80e7e3d697a4222939edd77cd5ca77ece16471ea4
2018-01-07 20:38:10 +00:00
drh acd6fdee98 Improved comments on the sqlar.c and compress.c extensions that describe
the differences between the "zlib format" used by SQLAR, the raw deflate
format used by ZIP, and the custom format used by compress.c.  No changes
to code.

FossilOrigin-Name: c13415c5caf06eaa73086c500907451dfcdfd1354ac4a9ab63edb7255edbfa1b
2018-01-07 19:52:28 +00:00
drh 1fa6d9f96f The shell detects and opens ZIP archives using the zipfile extension.
FossilOrigin-Name: 05c99eb8cefbb3366b6d4ae91e10aa0c82bdf5ea361f4b3375413783af9167ac
2018-01-06 21:46:01 +00:00
drh e37c0e1ce7 In the shell, include the ".archive" command only if compiling with
SQLITE_HAVE_ZLIB.  Add ".archive" to the ".help" output.

FossilOrigin-Name: 366469f5603367fabcadfc9ffe8cd1e23c649fea49a560178ca0858a16a7e4d1
2018-01-06 19:19:50 +00:00
drh afba1802a0 Better whitespace in the "CREATE TABLE sqlar()" statement for the ".ar"
command.

FossilOrigin-Name: 252ee55a7fc0b068b707af27bd912e684c28320996e78f0675217046b8c2fb49
2018-01-06 15:49:57 +00:00
drh 11be81d413 Improved output from ".schema --indent" when a column definition is followed
by a comment.

FossilOrigin-Name: 87da7efff07327278b1437f862ed8683c2d5d6ada7ea7461601a58f9762646b4
2018-01-06 15:46:20 +00:00
mistachkin 5e6f782f11 Remove a trailing tab from the Makefile for MSVC.
FossilOrigin-Name: 00cc26e34d2b81f140b031aa2f9ae0e2a4835cdd261d68f94b3e18a1388ca73d
2018-01-06 14:44:29 +00:00
mistachkin 0476b95c43 Minor tweaks to the Makefile for MSVC.
FossilOrigin-Name: 2f6cc5d8a0d9d961d1daf46e8725f7373f740afa788cf99ede9689f49d3a54ec
2018-01-06 14:43:33 +00:00
drh 4574db78a4 Add the appendvfs extension and code for the sqltclsh.exe executable.
FossilOrigin-Name: b0a43e325c53ec0df50fd41acffbbee65eac47b9318868e6959cd39da66fa8d6
2018-01-06 13:42:27 +00:00
drh 6b9986e84a Fix the appendvfs so that it leaves sqlite3_file->pMethods as NULL if it
fails to open.

FossilOrigin-Name: 46b341e3ad11b807ae50f001b970299de7ea0d523dbb639ee10f1d5aca5d958b
2018-01-06 13:33:21 +00:00
drh 9dea173154 Add sqltclsh.exe to the windows makefile.
FossilOrigin-Name: a6d5c7c2aabd70b4fb2bd8f6278f70272a5bd166adf2f7225ea582e10a46fafa
2018-01-06 04:34:05 +00:00
drh 1e506b5527 Make sure i64 and u64 typedefs are available throughout shell.c.
FossilOrigin-Name: 656fb5aab32f40412389e43de209867cedee1589533949cc8c01ba24218ea434
2018-01-05 21:01:37 +00:00
drh f5c75626ff Fix the shell.c.in amalgamator script so that it avoids generating
redundant typedef statements.

FossilOrigin-Name: 6c53c740cb4f62305689ea0a73beca83e71ed86707094e850bed975965c8c9f2
2018-01-05 20:30:54 +00:00
mistachkin 2f74b3c3ab MinGW does not define the S_ISLNK macro; therefore, define it in the shell when needed.
FossilOrigin-Name: 73023febbe57495a22db05904bd6ddff439d6c25970cbe87e0ba4a923f3e8a29
2018-01-05 20:26:06 +00:00
mistachkin f2e8aa637e Skip running the 'zipfile' test if the necessary static package cannot be loaded.
FossilOrigin-Name: 5bc816ec4010c20407396a1051e9f9b0a360ca27c0a99dafa867225cf974e306
2018-01-05 20:13:33 +00:00
mistachkin acae8c3e5d Fix shell compilation with MinGW by including the 'dirent.h' header.
FossilOrigin-Name: dfe510b51046a53c7f5c54fe73ec9de3364923eabd4b909c11984552e6bea406
2018-01-05 20:08:46 +00:00
drh 411dfd4e6d Fix the autoconf makefile so that it builds testfixture correctly.
FossilOrigin-Name: fbfe04c0b4f261789cbda3d2e98d12508181c283eab0bb757b081f0383e891bd
2018-01-05 19:49:54 +00:00
mistachkin b3ec2e1f4a Sync up the autoconf Makefile for MSVC.
FossilOrigin-Name: da8712bdb8f69dee9efb42b74d0b2ec10043f281c5f93e2724078bdf1370ecb1
2018-01-05 19:28:16 +00:00
mistachkin 992fdfc5d8 The 'releasetest' tool should pass the TCLDIR macro for MSVC to nmake.
FossilOrigin-Name: eaa9c0dda73808f1458f9968be59947636fbd4781c9fc535eb50bcaf790093c1
2018-01-05 19:27:19 +00:00
mistachkin 370732a83a For the MSVC Makefile, the 'sqlite3_checker.exe' target requires the Tcl library.
FossilOrigin-Name: 38109a47ffa977f1f962af2e183285d4e5db6fac2344868c5f1de64779dd0839
2018-01-05 19:25:52 +00:00
drh b2b7274e10 Add the ".ar" command to the command-line shell.
FossilOrigin-Name: 148b8aee78e40cab9a758a920589bd3ca8fc1c45cc93598bc50d96b85cd17e6c
2018-01-05 19:01:05 +00:00
drh 7ee8836e08 Fix a bug introduced by efforts to reduce compiler warnings in
check-in [364ac333b030f0]

FossilOrigin-Name: 1d6cee9ad448b10e69f351ef9dbec09110c5b189cba8734e637f41abe8f35bf8
2018-01-05 18:51:25 +00:00
mistachkin af23899318 In the Makefile for MSVC, the default target should not include binaries that link against the Tcl library.
FossilOrigin-Name: 5c6d0a1d58533feb4ea6926f4d3611664a275ad216492b424056276da38e84a2
2018-01-05 17:40:38 +00:00
mistachkin 5d7503a789 More adjustments to MSVC Makefile dependencies for zlib.
FossilOrigin-Name: bb650e5d14642b925c5ea65ba7991b35c4e941405d2557d542b99c66ca4bc130
2018-01-05 17:12:13 +00:00
mistachkin 9a5efdec70 Fix compiler warnings.
FossilOrigin-Name: 19aabccfe34c956599f33cd3ddc846816adc06784c2496838f1ef53059e038e5
2018-01-05 17:10:49 +00:00
drh c932033630 Fix missing dependencies for shell.c in all makefiles.
FossilOrigin-Name: 45495d3e256fef4d0669754726878ed17248fc781397ebb0421149ee9492f977
2018-01-05 16:23:43 +00:00
mistachkin 590522c18e In the Makefile for MSVC, only attempt to link against Tcl when it is needed. Also, only compile 'zipfile.c' when use of zlib is enabled.
FossilOrigin-Name: a33ad33cf031edee273afa4735c8564870465be22962a9c277e4ac43a307ff2c
2018-01-05 16:05:51 +00:00
mistachkin 91f7211caa Add some missing #ifdefs for building without zlib.
FossilOrigin-Name: c63fb1700c0f67d90857b1f3859c203880d0939f356a64d8ae7cafc814ea72bf
2018-01-05 16:03:52 +00:00
drh af2770f842 Fix compiler warnings.
FossilOrigin-Name: 364ac333b030f0e3372937df723f1098183da87913ba0e8ae162864ee24a50d3
2018-01-05 14:55:43 +00:00
dan 303b02cc0b Fix an LSM problem causing the wrong amount of "auto-work" to be performed
under fairly obscure circumstances.

FossilOrigin-Name: a4876672edea4e96103efd2463ce9a34a0b994a8744c941660940578aafbd454
2018-01-05 11:34:18 +00:00
dan 8503d6451b Fix an LSM crash that could occur if LSM_CONFIG_AUTOFLUSH was set to 0.
FossilOrigin-Name: 05346f83d587e6049da0e8ec5f62c749daa9e80359cf48f8c37e333e6a1e7d2a
2018-01-05 07:57:54 +00:00
mistachkin 47be3b23e9 Revise detection of 'tclsh.exe' in the Makefile for MSVC.
FossilOrigin-Name: 45fabd868dc690894f5a911d373a3d6410ba2d95d177307a42009afc8ae296cc
2018-01-05 01:22:37 +00:00
mistachkin 1152250b44 Enhance the 'zlib' build target for MSVC.
FossilOrigin-Name: 0bc3b76ec9b83f3034e282ea0369a53673e2cb64dde42e8cf5e800f6d642d527
2018-01-05 01:00:17 +00:00
mistachkin 3acaf4c07a Add missing #ifdef.
FossilOrigin-Name: a0e18aea0950f5ebdf4112f826ff64d24e8660b341031132dcb65bb15579ef1c
2018-01-05 00:53:03 +00:00
mistachkin 104958cab0 In the 'fileio' extension code for Win32, use the FILE_FLAG_BACKUP_SEMANTICS flag when setting the file times, just in case the file is actually a directory.
FossilOrigin-Name: 4f3444060057127bce81787ed83cb5225cdbdd577596bc3fb06a40be2208f238
2018-01-04 23:49:08 +00:00
mistachkin e55988074f Remove 'timespec' related code from the shell that has no effect and a (now) superfluous 'timespec' typedef from the Win32 dirent header file.
FossilOrigin-Name: 57dac995dd028e4b7c8ce6806f5769831715c1bb9b886318fceb3fa50563d537
2018-01-04 22:50:52 +00:00
mistachkin dfdfd8c7f2 Get the shell enhancements compiling with MSVC.
FossilOrigin-Name: 335387f9e0d4569097d34cd99cd332b38a282e9b7ae25f088eb47df5c25837ef
2018-01-04 22:46:08 +00:00
drh c76ed3d57d Merge in all recent trunk enhancements.
FossilOrigin-Name: 406f79183736b6ad360169b837172afef2c82a4312f5787db08c54167a44b15e
2018-01-04 19:54:55 +00:00
drh 35100fb194 Remove the snarky "_supported_" qualifier from the name of the
sqlite_offset() SQL function.

FossilOrigin-Name: a6eee0fcd89d3958f8720ebdb5f0a8558b4795d747128091dae283eb81c4f74f
2018-01-04 19:20:37 +00:00
drh 64c1990c00 Fix a broken documentation hyperlink. No code changes.
FossilOrigin-Name: d91e3f3d343d281af374dd23eea333e61228539023ad5c5aea622085e5863bc7
2018-01-04 16:40:44 +00:00
drh e616735cb1 Fix compiler warnings on Windows.
FossilOrigin-Name: 512b8e40c4ce2066d230b5f007bd704dc3577e21c55131ef07d90bf2fcf91b40
2018-01-03 23:54:18 +00:00