Author stestagg
Recipients stestagg, wdi2
Date 2020-12-10.23:12:46
SpamBayes Score -1.0
Marked as misclassified Yes
Message-id <1607641967.17.0.192211314526.issue42083@roundup.psfhosted.org>
In-reply-to
Content
It looks like the segfault was fixed in https://github.com/python/cpython/commit/88c2cfd9ffbcfc43fd1364f2984852a819547d43

as part of https://bugs.python.org/issue41832.

The code in this area of typeobject.c looks a bit different, now, but the backport seems simple?

Simple testcase:

#include <stdio.h>
#include <Python.h>
int main() {
    Py_Initialize();
    PyStructSequence_Field fields[2] = {
        {NULL, NULL}
    };
    PyStructSequence_Desc d = {"test", NULL, &fields[0], 0};
    PyStructSequence_NewType(&d);
    Py_Finalize();
}

Segfault reproducible on 3.8 and 3.9
History
Date User Action Args
2020-12-10 23:12:47stestaggsetrecipients: + stestagg, wdi2
2020-12-10 23:12:47stestaggsetmessageid: <1607641967.17.0.192211314526.issue42083@roundup.psfhosted.org>
2020-12-10 23:12:47stestagglinkissue42083 messages
2020-12-10 23:12:46stestaggcreate