Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

closes bpo-31525: require sqlite3_prepare_v2 #3666

Merged
merged 4 commits into from
Sep 20, 2017
Merged
Changes from 1 commit
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
Prev Previous commit
Next Next commit
delete another reset
  • Loading branch information
benjaminp committed Sep 20, 2017
commit 26b867072647710145f6fb0b4aa4a035b5423f93
12 changes: 1 addition & 11 deletions Modules/_sqlite/util.c
Original file line number Diff line number Diff line change
Expand Up @@ -47,17 +47,7 @@ int pysqlite_step(sqlite3_stmt* statement, pysqlite_Connection* connection)
*/
int _pysqlite_seterror(sqlite3* db, sqlite3_stmt* st)
{
int errorcode;

#if SQLITE_VERSION_NUMBER < 3003009
/* SQLite often doesn't report anything useful, unless you reset the statement first.
When using sqlite3_prepare_v2 this is not needed. */
if (st != NULL) {
(void)sqlite3_reset(st);
}
#endif

errorcode = sqlite3_errcode(db);
int errorcode = sqlite3_errcode(db);

switch (errorcode)
{
Expand Down