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
56ef1067
Commit
56ef1067
authored
Jul 17, 2016
by
Serhiy Storchaka
Browse files
Options
Browse Files
Download
Email Patches
Plain Diff
Issue #27419: Added temporary workaround for subinterpreters.
parent
d6558d8a
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 @
56ef1067
...
@@ -1526,7 +1526,10 @@ PyImport_ImportModuleLevelObject(PyObject *name, PyObject *given_globals,
...
@@ -1526,7 +1526,10 @@ PyImport_ImportModuleLevelObject(PyObject *name, PyObject *given_globals,
_PyImport_AcquireLock
();
_PyImport_AcquireLock
();
#endif
#endif
/* From this point forward, goto error_with_unlock! */
/* 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
)
{
if
(
builtins_import
==
NULL
)
{
PyErr_SetString
(
PyExc_ImportError
,
"__import__ not found"
);
PyErr_SetString
(
PyExc_ImportError
,
"__import__ not found"
);
goto
error_with_unlock
;
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