summaryrefslogtreecommitdiffstats
path: root/Modules/main.c
diff options
context:
space:
mode:
authorVictor Stinner <vstinner@redhat.com>2019-03-19 13:53:58 (GMT)
committerGitHub <noreply@github.com>2019-03-19 13:53:58 (GMT)
commitf5f336a819a3d881bb217bf8f9b5cacba03a4e45 (patch)
treea5673005a042063677a7eb14763cfa6e1d9a6d41 /Modules/main.c
parentfecc4f2b474f16062514e95a67e66080fd626e14 (diff)
downloadcpython-f5f336a819a3d881bb217bf8f9b5cacba03a4e45.zip
cpython-f5f336a819a3d881bb217bf8f9b5cacba03a4e45.tar.gz
cpython-f5f336a819a3d881bb217bf8f9b5cacba03a4e45.tar.bz2
bpo-36356: pymain_free() calls _PyRuntime_Finalize() (GH-12435)
Ensure that _PyRuntime_Finalize() is always call. This change fix a few memory leaks when running "python3 -V".
Diffstat (limited to 'Modules/main.c')
-rw-r--r--Modules/main.c1
1 files changed, 1 insertions, 0 deletions
diff --git a/Modules/main.c b/Modules/main.c
index 8f7a1bf..99396b7 100644
--- a/Modules/main.c
+++ b/Modules/main.c
@@ -839,6 +839,7 @@ pymain_free(void)
_PyPathConfig_ClearGlobal();
_Py_ClearStandardStreamEncoding();
_Py_ClearArgcArgv();
+ _PyRuntime_Finalize();
}