File tree Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Expand file tree Collapse file tree 2 files changed +5
-1
lines changed Original file line number Diff line number Diff line change @@ -10,6 +10,8 @@ What's New in Python 3.3.0 Beta 2?
10
10
Core and Builtins
11
11
-----------------
12
12
13
+ - Issue #15404: Refleak in PyMethodObject repr.
14
+
13
15
- Issue #15394: An issue in PyModule_Create that caused references to
14
16
be leaked on some error paths has been fixed. Patch by Julia Lawall.
15
17
Original file line number Diff line number Diff line change @@ -244,8 +244,10 @@ method_repr(PyMethodObject *a)
244
244
else {
245
245
klassname = _PyObject_GetAttrId (klass , & PyId___name__ );
246
246
if (klassname == NULL ) {
247
- if (!PyErr_ExceptionMatches (PyExc_AttributeError ))
247
+ if (!PyErr_ExceptionMatches (PyExc_AttributeError )) {
248
+ Py_XDECREF (funcname );
248
249
return NULL ;
250
+ }
249
251
PyErr_Clear ();
250
252
}
251
253
else if (!PyUnicode_Check (klassname )) {
You can’t perform that action at this time.
0 commit comments