• Victor Stinner's avatar
    Issue #18408: Don't check unicode consistency in _PyUnicode_HAS_UTF8_MEMORY() · e699e5a2
    Victor Stinner yazdı
    and _PyUnicode_HAS_WSTR_MEMORY() macros
    
    These macros are called in unicode_dealloc(), whereas the unicode object can be
    "inconsistent" if the creation of the object failed.
    
    For example, when unicode_subtype_new() fails on a memory allocation,
    _PyUnicode_CheckConsistency() fails with an assertion error because data is
    NULL.
    e699e5a2
unicodeobject.c 436 KB