summaryrefslogtreecommitdiff
path: root/Python/pylifecycle.c
diff options
context:
space:
mode:
authorSerhiy Storchaka <storchaka@gmail.com>2018-09-18 22:22:29 +0300
committerGitHub <noreply@github.com>2018-09-18 22:22:29 +0300
commit79d1c2e6c9d1bc1cf41ec3041801ca1a2b9a995b (patch)
tree024dfc74ad7bd5290180638b1290301ef928426f /Python/pylifecycle.c
parent4ba3b50bfe6d50cd82d208023ea23e203ab50589 (diff)
downloadcpython-git-79d1c2e6c9d1bc1cf41ec3041801ca1a2b9a995b.tar.gz
bpo-25711: Rewrite zipimport in pure Python. (GH-6809)
Diffstat (limited to 'Python/pylifecycle.c')
-rw-r--r--Python/pylifecycle.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/Python/pylifecycle.c b/Python/pylifecycle.c
index b735228ea5..06ea6b4dcd 100644
--- a/Python/pylifecycle.c
+++ b/Python/pylifecycle.c
@@ -191,7 +191,6 @@ initimport(PyInterpreterState *interp, PyObject *sysmod)
PyObject *importlib;
PyObject *impmod;
PyObject *value;
- _PyInitError err;
/* Import _importlib through its frozen version, _frozen_importlib. */
if (PyImport_ImportFrozenModule("_frozen_importlib") <= 0) {
@@ -233,11 +232,6 @@ initimport(PyInterpreterState *interp, PyObject *sysmod)
Py_DECREF(value);
Py_DECREF(impmod);
- err = _PyImportZip_Init();
- if (_Py_INIT_FAILED(err)) {
- return err;
- }
-
return _Py_INIT_OK();
}
@@ -252,7 +246,7 @@ initexternalimport(PyInterpreterState *interp)
return _Py_INIT_ERR("external importer setup failed");
}
Py_DECREF(value);
- return _Py_INIT_OK();
+ return _PyImportZip_Init();
}
/* Helper functions to better handle the legacy C locale