From 13dd8b368b81fa689a1f514e7950c2623fc361a5 Mon Sep 17 00:00:00 2001 From: Alon Zakai Date: Fri, 2 Mar 2007 20:06:31 +0000 Subject: [PATCH] --- src/deluge_core.cpp | 3 +++ 1 file changed, 3 insertions(+) diff --git a/src/deluge_core.cpp b/src/deluge_core.cpp index 524300b75..2be260efa 100644 --- a/src/deluge_core.cpp +++ b/src/deluge_core.cpp @@ -861,6 +861,9 @@ static PyObject *torrent_get_peer_info(PyObject *self, PyObject *args) "pieces", py_pieces ); + Py_DECREF(py_pieces); // Assuming the previous line does NOT steal the ref, then this is + // needed! + PyTuple_SetItem(ret, i, peer_info); };