summaryrefslogtreecommitdiffstats
path: root/Python/marshal.c
diff options
context:
space:
mode:
authorVictor Stinner <vstinner@redhat.com>2019-08-23 11:22:14 (GMT)
committerGitHub <noreply@github.com>2019-08-23 11:22:14 (GMT)
commitca9ae94a2aba35d94ac1ec081f9bcac3a13aebd3 (patch)
treee4fa80ff4ed455e5a19540c7f2b6da5b71a90aad /Python/marshal.c
parent994925b2cb28d5a77c9bdf056b6fdf99838fd848 (diff)
downloadcpython-ca9ae94a2aba35d94ac1ec081f9bcac3a13aebd3.zip
cpython-ca9ae94a2aba35d94ac1ec081f9bcac3a13aebd3.tar.gz
cpython-ca9ae94a2aba35d94ac1ec081f9bcac3a13aebd3.tar.bz2
bpo-37926: Fix PySys_SetArgvEx(0, NULL, 0) crash (GH-15415) (GH-15420)
empty_argv is no longer static in Python 3.8, but it is declared in a temporary scope, whereas argv keeps a reference to it. empty_argv memory (allocated on the stack) is reused by make_sys_argv() code which is inlined when using gcc -O3. Define empty_argv in PySys_SetArgvEx() body, to ensure that it remains valid for the whole lifetime of the PySys_SetArgvEx() call. (cherry picked from commit c48682509dc49b43fe914fe6c502bc390345d1c2)
Diffstat (limited to 'Python/marshal.c')
0 files changed, 0 insertions, 0 deletions