]> git.ipfire.org Git - thirdparty/Python/cpython.git/commit
closes bpo-38124: Fix bounds check in PyState_AddModule. (GH-16007)
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>
Thu, 12 Sep 2019 00:04:27 +0000 (17:04 -0700)
committerGitHub <noreply@github.com>
Thu, 12 Sep 2019 00:04:27 +0000 (17:04 -0700)
commita5a7102636de82e0687af7131357762337d49c7c
tree4df73b6e16ff0c31e2cda16590ba5ec4d227f25a
parent8af4e0c9942424b0dc6f5e882ce0bbd36f5fbb96
closes bpo-38124: Fix bounds check in PyState_AddModule. (GH-16007)

The >=, checking whether a module index was in already in the module-by-index list, needed to be strict.

Also, fold nested ifs into one and fix some bad spacing.
(cherry picked from commit 39de95b746c990e6a2fe9af5fad01747f58b2e5f)

Co-authored-by: Benjamin Peterson <benjamin@python.org>
Misc/NEWS.d/next/Core and Builtins/2019-09-12-00-14-01.bpo-38124.n6E0H7.rst [new file with mode: 0644]
Python/pystate.c