summaryrefslogtreecommitdiff
path: root/Mac/Contrib/PythonScript/PythonScript.py
diff options
context:
space:
mode:
authorGuido van Rossum <guido@python.org>2002-01-15 21:14:38 +0000
committerGuido van Rossum <guido@python.org>2002-01-15 21:14:38 +0000
commita472771dadd1e17a019f5effc8877ba20d914c56 (patch)
tree6a104975500c97fea39a1bee05c4cbb25c311cba /Mac/Contrib/PythonScript/PythonScript.py
parente60d3737ded2ec70bc291cd1cae5b5890866b6bd (diff)
downloadpython-a472771dadd1e17a019f5effc8877ba20d914c56.tar.gz
python-a472771dadd1e17a019f5effc8877ba20d914c56.zip
Backport revision 2.69.
SF patch #471839: Bug when extensions import extensions (Shane Hathaway) When an extension imports another extension in its initXXX() function, the variable _Py_PackageContext is prematurely reset to NULL. If the outer extension then calls Py_InitModule(), the extension is installed in sys.modules without its package name. The manifestation of this bug is a "SystemError: _PyImport_FixupExtension: module <package>.<extension> not loaded". To fix this, importdl.c just needs to retain the old value of _Py_PackageContext and restore it after the initXXX() method is called. The attached patch does this. This patch applies to Python 2.1.1 and the current CVS.
Diffstat (limited to 'Mac/Contrib/PythonScript/PythonScript.py')
0 files changed, 0 insertions, 0 deletions