Kaydet (Commit) a2e3585e authored tarafından Zackery Spytz's avatar Zackery Spytz Kaydeden (comit) Serhiy Storchaka

bpo-35356: Fix a possible reference leak in nis.maps(). (GH-10808)

üst 9724348b
...@@ -412,6 +412,7 @@ nis_maps (PyObject *self, PyObject *args, PyObject *kwdict) ...@@ -412,6 +412,7 @@ nis_maps (PyObject *self, PyObject *args, PyObject *kwdict)
PyObject *str = PyUnicode_FromString(maps->map); PyObject *str = PyUnicode_FromString(maps->map);
if (!str || PyList_Append(list, str) < 0) if (!str || PyList_Append(list, str) < 0)
{ {
Py_XDECREF(str);
Py_DECREF(list); Py_DECREF(list);
list = NULL; list = NULL;
break; break;
......
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