Skip to content
Snippets Groups Projects
Commit 06cba6982702 authored by Pablo Galindo's avatar Pablo Galindo
Browse files

Use Py_NewRef in Modules/_struct.c (GH-23981)

parent ce349f8c1338
No related branches found
No related tags found
No related merge requests found
......@@ -1442,8 +1442,7 @@
self = alloc_func(type, 0);
if (self != NULL) {
PyStructObject *s = (PyStructObject*)self;
Py_INCREF(Py_None);
s->s_format = Py_None;
s->s_format = Py_NewRef(Py_None);
s->s_codes = NULL;
s->s_size = -1;
s->s_len = -1;
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment