sqlite_reset according to
http://www.sqlite.org/c3ref/prepare.html
is no longer required
Details
Details
Diff Detail
Diff Detail
- Repository
- R15 KDb
- Lint
Lint Skipped - Unit
Unit Tests Skipped
Comment Actions
Yes, second call to sqlite3_reset() used on error (actually not by us) isn't necessary. But the first call is, otherwise old values bound to columns won't be removed.
From https://www.sqlite.org/c3ref/reset.html:
The sqlite3_reset() function is called to reset a prepared statement object back to its initial state, ready to be re-executed.
So if I am not mistaken sqlite3_reset() stays and by adding _v2 we will get more detailed error codes.
BTW, the more fresh shell.c from here https://www.sqlite.org/src/artifact/dcd7a83645ef2a58 from the official SQLite3 code also uses sqlite3_reset() with sqlite3_prepare_v2().
Comment Actions
Good! Almost done, please also change 2 occurrences of sqlite3_prepare in the code comments and push.