8000 gh-117953: Small Cleanup of Extensions-Related Machinery Code by ericsnowcurrently · Pull Request #118167 · python/cpython · GitHub
[go: up one dir, main page]

Skip to content

gh-117953: Small Cleanup of Extensions-Related Machinery Code #118167

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
Prev Previous commit
Add a comment.
  • Loading branch information
ericsnowcurrently committed Apr 23, 2024
commit be500203a50368f484d1f0bb8e76a4a0036b3205
3 changes: 3 additions & 0 deletions Python/import.c
Original file line number Diff line number Diff line change
Expand Up @@ -3769,6 +3769,9 @@ _imp_create_dynamic_impl(PyObject *module, PyObject *spec, PyObject *file)

/* Is multi-phase init or this is the first time being loaded. */

/* We would move this (and the fclose() below) into
* _PyImport_GetModInitFunc(), but it isn't clear if the intervening
* code relies on fp still being open. */
if (file != NULL) {
fp = _Py_fopen_obj(filename, "r");
if (fp == NULL) {
Expand Down
0