From bfa255afa47273dcbe67a7eb66c27df8aea89179 Mon Sep 17 00:00:00 2001 From: Dave Abrahams Date: Tue, 31 Oct 2000 23:43:18 +0000 Subject: [PATCH] Reference-counting bug fix, thanks to Mark Evans [SVN r8088] --- objects.cpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/objects.cpp b/objects.cpp index d13e6fb9..5c4a1b8a 100644 --- a/objects.cpp +++ b/objects.cpp @@ -16,7 +16,7 @@ namespace py { template T object_from_python(PyObject* p, Type) { - Ptr x(p); + Ptr x(p, Ptr::new_ref); if (!T::accepts(x)) { PyErr_SetString(PyExc_TypeError, p->ob_type->tp_name);