Skip to content
Projects
Groups
Snippets
Help
Loading...
Help
Support
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
C
cpython
Project overview
Project overview
Details
Activity
Releases
Repository
Repository
Files
Commits
Branches
Tags
Contributors
Graph
Compare
Issues
0
Issues
0
List
Boards
Labels
Milestones
Merge Requests
0
Merge Requests
0
Analytics
Analytics
Repository
Value Stream
Wiki
Wiki
Members
Members
Collapse sidebar
Close sidebar
Activity
Graph
Create a new issue
Commits
Issue Boards
Open sidebar
Kirill Smelkov
cpython
Commits
caaf53e7
Commit
caaf53e7
authored
Jul 17, 2016
by
Serhiy Storchaka
Browse files
Options
Browse Files
Download
Plain Diff
Issue #27419: Added temporary workaround for subinterpreters.
parents
740527ab
80ab069f
Changes
1
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
4 additions
and
1 deletion
+4
-1
Python/import.c
Python/import.c
+4
-1
No files found.
Python/import.c
View file @
caaf53e7
...
...
@@ -1557,7 +1557,10 @@ PyImport_ImportModuleLevelObject(PyObject *name, PyObject *given_globals,
_PyImport_AcquireLock
();
#endif
/* From this point forward, goto error_with_unlock! */
builtins_import
=
_PyDict_GetItemId
(
interp
->
builtins_copy
,
&
PyId___import__
);
/* XXX interp->builtins_copy is NULL in subinterpreter! */
builtins_import
=
_PyDict_GetItemId
(
interp
->
builtins_copy
?
interp
->
builtins_copy
:
interp
->
builtins
,
&
PyId___import__
);
if
(
builtins_import
==
NULL
)
{
PyErr_SetString
(
PyExc_ImportError
,
"__import__ not found"
);
goto
error_with_unlock
;
...
...
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment