[New-bugs-announce] [issue46605] Py_XDECREF() module on fail in Py_mod_exec
ov2k
report at bugs.python.org
Tue Feb 1 16:49:08 EST 2022
New submission from ov2k <ov2k.github at gmail.com>:
In some of the xx modules, a Py_mod_exec function steals a reference to the module argument when an error occurs (Py_XDECREF(m) after goto fail). It's a bit pernicious given the modules' stated intent to be used as a template, although I'm not sure how often this has actually happened. At the very least, I haven't noticed this outside the xx modules.
For Python <= 3.9, this affects xx_exec() in xxmodule.c and xx_modexec() in xxlimited.c. For Python >= 3.10, this affects xx_exec() in xxmodule.c and xx_modexec() in xxlimited_35.c.
----------
components: Extension Modules
messages: 412315
nosy: ov2k
priority: normal
severity: normal
status: open
title: Py_XDECREF() module on fail in Py_mod_exec
type: behavior
versions: Python 3.10, Python 3.11, Python 3.7, Python 3.8, Python 3.9
_______________________________________
Python tracker <report at bugs.python.org>
<https://bugs.python.org/issue46605>
_______________________________________
More information about the New-bugs-announce
mailing list