-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
-C Disable\squery\sflattening\swhen\sthe\souter\squery\sis\sa\scompound\sSELECT\sand\nthe\sinner\squery\shas\sa\sLIMIT\sclause.\s\sTicket\s[02a8e81d44].
-D 2010-04-15T23:24:29
+C Change\ssqlite3_step()\sso\sthat\sit\sautomatically\scalls\ssqlite3_reset()\sinstead\nof\sreturning\sSQLITE_MISUSE\swhen\sinvoked\son\sa\sprepared\sstatement\sthat\npreviously\sreturned\sany\svalue\sother\sthan\sSQLITE_ROW.
+D 2010-04-17T12:53:20
F Makefile.arm-wince-mingw32ce-gcc fcd5e9cd67fe88836360bb4f9ef4cb7f8e2fb5a0
F Makefile.in 4f2f967b7e58a35bb74fb7ec8ae90e0f4ca7868b
F Makefile.linux-gcc d53183f4aa6a9192d249731c90dbdffbd2c68654
F src/rowset.c 69afa95a97c524ba6faf3805e717b5b7ae85a697
F src/select.c b7c9a40bc1567bceff52ad4b73108734ee4bf268
F src/shell.c c40427c7245535a04a9cb4a417b6cc05c022e6a4
-F src/sqlite.h.in 0aeb53778e1591032fdf12ba7aa059250beb480a
+F src/sqlite.h.in dc98616304e3e776008655671d81e3ad3028ada7
F src/sqlite3ext.h 69dfb8116af51b84a029cddb3b35062354270c89
F src/sqliteInt.h bd7ff54663bdd5b57e0eb8b49aca5a3a3c60119a
F src/sqliteLimit.h 3afab2291762b5d09ae20c18feb8e9fa935a60a6
F src/vdbe.c 2abd931ea2aec3eacc6426677f40cc5a1071d34e
F src/vdbe.h 471f6a3dcec4817ca33596fe7f6654d56c0e75f3
F src/vdbeInt.h 19ebc8c2a2e938340051ee65af3f377fb99102d1
-F src/vdbeapi.c 74c25680046a116b24b95393914d3669c23305dc
+F src/vdbeapi.c 11bcc381e81e797fcf3e81fa6a14ec16a04801cc
F src/vdbeaux.c 3028b2d50df39697e21263685349b5ff1333a29b
F src/vdbeblob.c 5327132a42a91e8b7acfb60b9d2c3b1c5c863e0e
F src/vdbemem.c 2a82f455f6ca6f78b59fb312f96054c04ae0ead1
F test/boundary4.test 89e02fa66397b8a325d5eb102b5806f961f8ec4b
F test/busy.test 76b4887f8b9160ba903c1ac22e8ff406ad6ae2f0
F test/cache.test 3ff445c445742a7b6b9ba6e1d62a25263f9424b9
-F test/capi2.test 172c717ed101e78e0798dd21b9896a22366f35b4
+F test/capi2.test 00032d7504b9c14f1b36331670c5e7b0f73e3c5d
F test/capi3.test 168e2cd66c58c510955b0f299750e4de73b8d952
F test/capi3b.test 664eb55318132f292f2c436f90906f578cad6b97
F test/capi3c.test 493385107dcedfaf4f2b1c3738c8c1fa00362006
F test/filectrl.test 8923a6dc7630f31c8a9dd3d3d740aa0922df7bf8
F test/filefmt.test 84e3d0fe9f12d0d2ac852465c6f8450aea0d6f43
F test/fkey1.test 01c7de578e11747e720c2d9aeef27f239853c4da
-F test/fkey2.test e71f5baf9bb42cdba4700d73cba6f4d82fd6b925
+F test/fkey2.test 82652daf32ec5a40634a10bc8db571b84d39c7fe
F test/fkey3.test 42f88d6048d8dc079e2a8cf7baad1cc1483a7620
F test/fkey_malloc.test a5ede29bd2f6e56dea78c3d43fb86dd696c068c8
F test/format4.test 1f0cac8ff3895e9359ed87e41aaabee982a812eb
F tool/speedtest8.c 2902c46588c40b55661e471d7a86e4dd71a18224
F tool/speedtest8inst1.c 293327bc76823f473684d589a8160bde1f52c14e
F tool/vdbe-compress.tcl d70ea6d8a19e3571d7ab8c9b75cba86d1173ff0f
-P f538d759beda67e042b66181b65bd432488f7650
-R 34d0a17088c0fdff5f60f2ea4cf2882d
+P f96782b389b5b97b488dc5814f7082e0393f64cd
+R b3683c8d5f87dead098717870c446ce4
U drh
-Z b46bcb95ee573d80fced144df93d24f1
+Z 68bc4fd82825f4b7f1278d3f78ee95b8
-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.4.6 (GNU/Linux)
-iD8DBQFLx6AxoxKgR168RlERAq3yAJ9VLNfRM+IKVowVDGm7aiEH4HuZmQCaA/ai
-zk4R64zbGoGnQ/UpEadFxjM=
-=0vth
+iD8DBQFLya9GoxKgR168RlERAvQaAJwLUmtTGSRsZdMt+rOX4V9Acu7enQCdFgG+
+yMxp/Ep2vaOwFANf9gUAX1Q=
+=yLEB
-----END PGP SIGNATURE-----
** be the case that the same database connection is being used by two or
** more threads at the same moment in time.
**
+** For all versions of SQLite up to and including 3.6.23.1, it was required
+** after sqlite3_step() returned anything other than [SQLITE_ROW] that
+** [sqlite3_reset()] be called before any subsequent invocation of
+** sqlite3_step(). Failure to invoke [sqlite3_reset()] in this way would
+** result in an [SQLITE_MISUSE] return from sqlite3_step(). But after
+** version 3.6.23.1, sqlite3_step() began calling [sqlite3_reset()]
+** automatically in this circumstance rather than returning [SQLITE_MISUSE].
+**
** <b>Goofy Interface Alert:</b> In the legacy interface, the sqlite3_step()
** API always returns a generic error code, [SQLITE_ERROR], following any
** error other than [SQLITE_BUSY] and [SQLITE_MISUSE]. You must call
assert(p);
if( p->magic!=VDBE_MAGIC_RUN ){
- sqlite3_log(SQLITE_MISUSE,
- "attempt to step a halted statement: [%s]", p->zSql);
- return SQLITE_MISUSE_BKPT;
+ /* We used to require that sqlite3_reset() be called before retrying
+ ** sqlite3_step() after any error. But after 3.6.23, we changed this
+ ** so that sqlite3_reset() would be called automatically instead of
+ ** throwing the error.
+ */
+ sqlite3_reset((sqlite3_stmt*)p);
}
/* Check that malloc() has not failed. If it has, return early. */
do_test capi2-1.7 {
list [sqlite3_column_count $VM] [get_row_values $VM] [get_column_names $VM]
} {2 {} {name rowid text INTEGER}}
-do_test capi2-1.8-misuse {
+
+# This used to be SQLITE_MISUSE. But now we automatically reset prepared
+# statements.
+do_test capi2-1.8 {
sqlite3_step $VM
-} {SQLITE_MISUSE}
+} {SQLITE_ROW}
# Update: In v2, once SQLITE_MISUSE is returned the statement handle cannot
# be interrogated for more information. However in v3, since the column
# count, names and types are determined at compile time, these are still
# accessible after an SQLITE_MISUSE error.
do_test capi2-1.9 {
+ sqlite3_reset $VM
list [sqlite3_column_count $VM] [get_row_values $VM] [get_column_names $VM]
} {2 {} {name rowid text INTEGER}}
do_test capi2-1.10 {