We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 6ec81c7 commit 1b6e462Copy full SHA for 1b6e462
1 file changed
Python/ceval.c
@@ -5024,6 +5024,10 @@ import_from(PyObject *v, PyObject *name)
5024
pkgpath = PyModule_GetFilenameObject(v);
5025
if (pkgname == NULL) {
5026
pkgname_or_unknown = PyUnicode_FromString("<unknown module name>");
5027
+ if (pkgname_or_unknown == NULL) {
5028
+ Py_XDECREF(pkgpath);
5029
+ return NULL;
5030
+ }
5031
} else {
5032
pkgname_or_unknown = pkgname;
5033
}
0 commit comments