diff options
author | Serhiy Storchaka <storchaka@gmail.com> | 2020-10-04 22:28:00 (GMT) |
---|---|---|
committer | GitHub <noreply@github.com> | 2020-10-04 22:28:00 (GMT) |
commit | 09a7b3b618cd02694a0bc8abfa24c75f0e659407 (patch) | |
tree | fe81737f24de56c6cd798f261dc73df39e81aa85 /Python/pytime.c | |
parent | 28cd96f2e5cfb16566a75dca8473b71889746f10 (diff) | |
download | cpython-09a7b3b618cd02694a0bc8abfa24c75f0e659407.zip cpython-09a7b3b618cd02694a0bc8abfa24c75f0e659407.tar.gz cpython-09a7b3b618cd02694a0bc8abfa24c75f0e659407.tar.bz2 |
[3.8] bpo-41909: Enable previously disabled recursion checks. (GH-22536) (GH-22551)
Enable recursion checks which were disabled when get __bases__ of
non-type objects in issubclass() and isinstance() and when intern
strings. It fixes a stack overflow when getting __bases__ leads
to infinite recursion.
Originally recursion checks was disabled for PyDict_GetItem() which
silences all errors including the one raised in case of detected
recursion and can return incorrect result. But now the code uses
PyDict_GetItemWithError() and PyDict_SetDefault() instead.
(cherry picked from commit 9ece9cd65cdeb0a1f6e60475bbd0219161c348ac)
Diffstat (limited to 'Python/pytime.c')
0 files changed, 0 insertions, 0 deletions