SIGN IN SIGN UP

[3.13] gh-130163: Fix crashes related to PySys_GetObject() (GH-130503) (GH-130556)

The use of PySys_GetObject() and _PySys_GetAttr(), which return a borrowed
reference, has been replaced by using one of the following functions, which
return a strong reference and distinguish a missing attribute from an error:
_PySys_GetOptionalAttr(), _PySys_GetOptionalAttrString(),
_PySys_GetRequiredAttr(), and _PySys_GetRequiredAttrString().
(cherry picked from commit 0ef4ffeefd1737c18dc9326133c7894d58108c2e)
S
Serhiy Storchaka committed
7c1b76fce8c8df00da38830f72dbdde6881a33be
Parent: b0d3f49
Committed by GitHub <noreply@github.com> on 2/25/2025, 10:50:26 PM