Skip to content

Commit c83356c

Browse files
shihai1991benjaminp
authored andcommitted
closes bpo-37300: Remove unnecessary Py_XINCREF in classobject.c. (pythonGH-14120)
1 parent 5600b5e commit c83356c

File tree

2 files changed

+2
-1
lines changed

2 files changed

+2
-1
lines changed
Original file line numberDiff line numberDiff line change
@@ -0,0 +1 @@
1+
Remove an unnecssary Py_XINCREF in classobject.c.

Objects/classobject.c

+1-1
Original file line numberDiff line numberDiff line change
@@ -110,7 +110,7 @@ PyMethod_New(PyObject *func, PyObject *self)
110110
im->im_weakreflist = NULL;
111111
Py_INCREF(func);
112112
im->im_func = func;
113-
Py_XINCREF(self);
113+
Py_INCREF(self);
114114
im->im_self = self;
115115
im->vectorcall = method_vectorcall;
116116
_PyObject_GC_TRACK(im);

0 commit comments

Comments
 (0)