[Python-checkins] bpo-27334: Fix reference leak introduced by GH-26202 (GH-27942)

ambv webhook-mailer at python.org
Wed Aug 25 09:58:02 EDT 2021


https://github.com/python/cpython/commit/a3c11cebf174e0c822eda8c545f7548269ce7a25
commit: a3c11cebf174e0c822eda8c545f7548269ce7a25
branch: main
author: Erlend Egeberg Aasland <erlend.aasland at innova.no>
committer: ambv <lukasz at langa.pl>
date: 2021-08-25T15:57:54+02:00
summary:

bpo-27334: Fix reference leak introduced by GH-26202 (GH-27942)

files:
M Modules/_sqlite/connection.c

diff --git a/Modules/_sqlite/connection.c b/Modules/_sqlite/connection.c
index 1bc045523a252..19d30d24d7f2e 100644
--- a/Modules/_sqlite/connection.c
+++ b/Modules/_sqlite/connection.c
@@ -1807,6 +1807,7 @@ pysqlite_connection_exit_impl(pysqlite_Connection *self, PyObject *exc_type,
                 _PyErr_ChainExceptions(exc, val, tb);
             }
             else {
+                Py_DECREF(result);
                 PyErr_Restore(exc, val, tb);
             }
         }



More information about the Python-checkins mailing list