mirror of
https://git.jabber.space/devs/cproof.git
synced 2026-07-18 23:36:21 +00:00
Fix memory leaks
This commit is contained in:
@@ -740,7 +740,9 @@ python_api_settings_get_string(PyObject *self, PyObject *args)
|
||||
disable_python_threads();
|
||||
|
||||
if (res) {
|
||||
return Py_BuildValue("s", res);
|
||||
PyObject *pyres = Py_BuildValue("s", res);
|
||||
free(res);
|
||||
return pyres;
|
||||
} else {
|
||||
Py_RETURN_NONE;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user