summaryrefslogtreecommitdiffstats
path: root/Misc
diff options
context:
space:
mode:
authorVictor Stinner <vstinner@python.org>2020-07-03 12:15:53 (GMT)
committerGitHub <noreply@github.com>2020-07-03 12:15:53 (GMT)
commit91e1bc18bd467a13bceb62e16fbc435b33381c82 (patch)
treec0b38793683a3a4f0c72b471e14ca0bc622bd33d /Misc
parent74419f0c64959bb8392fcf3659058410423038e1 (diff)
downloadcpython-91e1bc18bd467a13bceb62e16fbc435b33381c82.zip
cpython-91e1bc18bd467a13bceb62e16fbc435b33381c82.tar.gz
cpython-91e1bc18bd467a13bceb62e16fbc435b33381c82.tar.bz2
bpo-41194: The _ast module cannot be loaded more than once (GH-21290)
Fix a crash in the _ast module: it can no longer be loaded more than once. It now uses a global state rather than a module state. * Move _ast module state: use a global state instead. * Set _astmodule.m_size to -1, so the extension cannot be loaded more than once.
Diffstat (limited to 'Misc')
-rw-r--r--Misc/NEWS.d/next/Library/2020-07-03-13-15-08.bpo-41194.djrKjs.rst2
1 files changed, 2 insertions, 0 deletions
diff --git a/Misc/NEWS.d/next/Library/2020-07-03-13-15-08.bpo-41194.djrKjs.rst b/Misc/NEWS.d/next/Library/2020-07-03-13-15-08.bpo-41194.djrKjs.rst
new file mode 100644
index 0000000..d63a0e5
--- /dev/null
+++ b/Misc/NEWS.d/next/Library/2020-07-03-13-15-08.bpo-41194.djrKjs.rst
@@ -0,0 +1,2 @@
+Fix a crash in the ``_ast`` module: it can no longer be loaded more than once.
+It now uses a global state rather than a module state.