summaryrefslogtreecommitdiffstats
path: root/Modules
diff options
context:
space:
mode:
authorErlend Egeberg Aasland <erlend.aasland@innova.no>2021-02-26 14:30:22 (GMT)
committerGitHub <noreply@github.com>2021-02-26 14:30:22 (GMT)
commit5e48e836883ac577acd69c7b9bdfe5c439cef47f (patch)
treec53d4b1d06e9501051d89747ff375436955f6938 /Modules
parent7956ef884965ac6f9f7f2a27b835ea80e471c886 (diff)
downloadcpython-5e48e836883ac577acd69c7b9bdfe5c439cef47f.zip
cpython-5e48e836883ac577acd69c7b9bdfe5c439cef47f.tar.gz
cpython-5e48e836883ac577acd69c7b9bdfe5c439cef47f.tar.bz2
bpo-43294: Remove unused variables in pysqlite_connection_*() (GH-24658)
Diffstat (limited to 'Modules')
-rw-r--r--Modules/_sqlite/connection.c10
1 files changed, 4 insertions, 6 deletions
diff --git a/Modules/_sqlite/connection.c b/Modules/_sqlite/connection.c
index 53d358e..9bf2a35 100644
--- a/Modules/_sqlite/connection.c
+++ b/Modules/_sqlite/connection.c
@@ -367,11 +367,11 @@ int pysqlite_check_connection(pysqlite_Connection* con)
PyObject* _pysqlite_connection_begin(pysqlite_Connection* self)
{
int rc;
- const char* tail;
sqlite3_stmt* statement;
Py_BEGIN_ALLOW_THREADS
- rc = sqlite3_prepare_v2(self->db, self->begin_statement, -1, &statement, &tail);
+ rc = sqlite3_prepare_v2(self->db, self->begin_statement, -1, &statement,
+ NULL);
Py_END_ALLOW_THREADS
if (rc != SQLITE_OK) {
@@ -411,7 +411,6 @@ pysqlite_connection_commit_impl(pysqlite_Connection *self)
/*[clinic end generated code: output=3da45579e89407f2 input=39c12c04dda276a8]*/
{
int rc;
- const char* tail;
sqlite3_stmt* statement;
if (!pysqlite_check_thread(self) || !pysqlite_check_connection(self)) {
@@ -421,7 +420,7 @@ pysqlite_connection_commit_impl(pysqlite_Connection *self)
if (!sqlite3_get_autocommit(self->db)) {
Py_BEGIN_ALLOW_THREADS
- rc = sqlite3_prepare_v2(self->db, "COMMIT", -1, &statement, &tail);
+ rc = sqlite3_prepare_v2(self->db, "COMMIT", -1, &statement, NULL);
Py_END_ALLOW_THREADS
if (rc != SQLITE_OK) {
_pysqlite_seterror(self->db, NULL);
@@ -461,7 +460,6 @@ pysqlite_connection_rollback_impl(pysqlite_Connection *self)
/*[clinic end generated code: output=b66fa0d43e7ef305 input=12d4e8d068942830]*/
{
int rc;
- const char* tail;
sqlite3_stmt* statement;
if (!pysqlite_check_thread(self) || !pysqlite_check_connection(self)) {
@@ -472,7 +470,7 @@ pysqlite_connection_rollback_impl(pysqlite_Connection *self)
pysqlite_do_all_statements(self, ACTION_RESET, 1);
Py_BEGIN_ALLOW_THREADS
- rc = sqlite3_prepare_v2(self->db, "ROLLBACK", -1, &statement, &tail);
+ rc = sqlite3_prepare_v2(self->db, "ROLLBACK", -1, &statement, NULL);
Py_END_ALLOW_THREADS
if (rc != SQLITE_OK) {
_pysqlite_seterror(self->db, NULL);