Kaydet (Commit) ecd20109 authored tarafından Gerhard Häring's avatar Gerhard Häring

Fixed a memory leak that was introduced with incorrect usage of the Python weak

reference API in pysqlite 2.2.1.

Bumbed pysqlite version number to upcoming pysqlite 2.3.1 release.
üst 7cea65cc
......@@ -664,7 +664,7 @@ void _drop_unused_statement_references(Connection* self)
for (i = 0; i < PyList_Size(self->statements); i++) {
weakref = PyList_GetItem(self->statements, i);
if (weakref != Py_None) {
if (PyWeakref_GetObject(weakref) != Py_None) {
if (PyList_Append(new_list, weakref) != 0) {
Py_DECREF(new_list);
return;
......
......@@ -25,7 +25,7 @@
#define PYSQLITE_MODULE_H
#include "Python.h"
#define PYSQLITE_VERSION "2.3.0"
#define PYSQLITE_VERSION "2.3.1"
extern PyObject* Error;
extern PyObject* Warning;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment