summaryrefslogtreecommitdiff
path: root/Python/pathconfig.c
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2019-10-01 03:26:04 -0700
committerGitHub <noreply@github.com>2019-10-01 03:26:04 -0700
commitd49f096cc41f57155efe71cd089c29b38c218488 (patch)
tree1830b017fe1259e6d5cc27390f0331a83b7d8ba2 /Python/pathconfig.c
parent938c00ca9e4207a2531041edff2e82490b02047f (diff)
downloadcpython-git-d49f096cc41f57155efe71cd089c29b38c218488.tar.gz
bpo-38304: PyConfig_InitPythonConfig() cannot fail anymore (GH-16509)
PyConfig_InitPythonConfig() and PyConfig_InitIsolatedConfig() no longer return PyStatus: they cannot fail anymore. (cherry picked from commit 8462a4936b3a551dc546a6adea04a70b0a07ca67) Co-authored-by: Victor Stinner <vstinner@redhat.com>
Diffstat (limited to 'Python/pathconfig.c')
-rw-r--r--Python/pathconfig.c9
1 files changed, 2 insertions, 7 deletions
diff --git a/Python/pathconfig.c b/Python/pathconfig.c
index ff4bbf2a97..7f3fdcc103 100644
--- a/Python/pathconfig.c
+++ b/Python/pathconfig.c
@@ -432,16 +432,11 @@ _PyConfig_InitPathConfig(PyConfig *config)
static PyStatus
pathconfig_global_read(_PyPathConfig *pathconfig)
{
- PyStatus status;
PyConfig config;
-
- status = _PyConfig_InitCompatConfig(&config);
- if (_PyStatus_EXCEPTION(status)) {
- goto done;
- }
+ _PyConfig_InitCompatConfig(&config);
/* Call _PyConfig_InitPathConfig() */
- status = PyConfig_Read(&config);
+ PyStatus status = PyConfig_Read(&config);
if (_PyStatus_EXCEPTION(status)) {
goto done;
}