Commit f17101a3 authored by Benjamin Peterson's avatar Benjamin Peterson

merge 3.2

parents 2945a998 5c2b09e8
...@@ -200,11 +200,13 @@ void pysqlite_do_all_statements(pysqlite_Connection* self, int action, int reset ...@@ -200,11 +200,13 @@ void pysqlite_do_all_statements(pysqlite_Connection* self, int action, int reset
weakref = PyList_GetItem(self->statements, i); weakref = PyList_GetItem(self->statements, i);
statement = PyWeakref_GetObject(weakref); statement = PyWeakref_GetObject(weakref);
if (statement != Py_None) { if (statement != Py_None) {
Py_INCREF(statement);
if (action == ACTION_RESET) { if (action == ACTION_RESET) {
(void)pysqlite_statement_reset((pysqlite_Statement*)statement); (void)pysqlite_statement_reset((pysqlite_Statement*)statement);
} else { } else {
(void)pysqlite_statement_finalize((pysqlite_Statement*)statement); (void)pysqlite_statement_finalize((pysqlite_Statement*)statement);
} }
Py_DECREF(statement);
} }
} }
......
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