Kaydet (Commit) 409f9023 authored tarafından Richard Oudkerk's avatar Richard Oudkerk

Issue #18180: Fix ref leak in _PyImport_GetDynLoadWindows().

üst a822d366
...@@ -12,6 +12,8 @@ What's New in Python 3.3.3 release candidate 1? ...@@ -12,6 +12,8 @@ What's New in Python 3.3.3 release candidate 1?
Core and Builtins Core and Builtins
----------------- -----------------
- Issue #18180: Fix ref leak in _PyImport_GetDynLoadWindows().
- Issue #18038: SyntaxError raised during compilation sources with illegal - Issue #18038: SyntaxError raised during compilation sources with illegal
encoding now always contains an encoding name. encoding now always contains an encoding name.
......
...@@ -262,8 +262,9 @@ dl_funcptr _PyImport_GetDynLoadWindows(const char *shortname, ...@@ -262,8 +262,9 @@ dl_funcptr _PyImport_GetDynLoadWindows(const char *shortname,
theLength)); theLength));
} }
if (message != NULL) { if (message != NULL) {
PyErr_SetImportError(message, PyUnicode_FromString(shortname), PyObject *shortname_obj = PyUnicode_FromString(shortname);
pathname); PyErr_SetImportError(message, shortname_obj, pathname);
Py_XDECREF(shortname_obj);
Py_DECREF(message); Py_DECREF(message);
} }
return NULL; return NULL;
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment