فهرست منبع

coercion memory leak fix, part 2

David Rose 16 سال پیش
والد
کامیت
638e46d489
1فایلهای تغییر یافته به همراه1 افزوده شده و 0 حذف شده
  1. 1 0
      dtool/src/interrogatedb/py_panda.cxx

+ 1 - 0
dtool/src/interrogatedb/py_panda.cxx

@@ -88,6 +88,7 @@ attempt_coercion(PyObject *self, Dtool_PyTypedObject *classdef,
           (*coerced) = PyList_New(0);
         }
         PyList_Append(*coerced, obj);
+        Py_DECREF(obj);
         return result;
       }
       // Some problem getting the C++ pointer from our created