[New-bugs-announce] [issue43687] use unicode_state empty string before unicode_init. without define WITH_DOC_STRINGS
junyixie
report at bugs.python.org
Wed Mar 31 23:39:21 EDT 2021
New submission from junyixie <xie.junyi at outlook.com>:
use unicode_state empty string before unicode_init. without define WITH_DOC_STRINGS.
PyType_Ready call PyUnicode_FromString, if doc string striped, cause crash.
unicode_get_empty() must not be called before _PyUnicode_Init() or after _PyUnicode_Fini()
PyType_Ready
```
const char *old_doc = _PyType_DocWithoutSignature(type->tp_name,type->tp_doc);
PyObject *doc = PyUnicode_FromString(old_doc);
```
----------
messages: 389950
nosy: JunyiXie
priority: normal
severity: normal
status: open
title: use unicode_state empty string before unicode_init. without define WITH_DOC_STRINGS
type: crash
versions: Python 3.10
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue43687>
_______________________________________
More information about the New-bugs-announce
mailing list