Commit d7652be5 authored by Hirokazu Yamamoto's avatar Hirokazu Yamamoto

Issue #5041: Fixed memory leak.

parent 96b5b03d
......@@ -2894,12 +2894,14 @@ static PyObject *
imp_find_module(PyObject *self, PyObject *args)
{
char *name;
PyObject *path = NULL;
PyObject *ret, *path = NULL;
if (!PyArg_ParseTuple(args, "es|O:find_module",
Py_FileSystemDefaultEncoding, &name,
&path))
return NULL;
return call_find_module(name, path);
ret = call_find_module(name, path);
PyMem_Free(name);
return ret;
}
static PyObject *
......
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