Module: kamailio
Branch: master
Commit: dc00778decd5a7c91208fb1ae31d875677a2b9de
URL:
https://github.com/kamailio/kamailio/commit/dc00778decd5a7c91208fb1ae31d875…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2017-07-21T08:45:18+02:00
app_python: free buf in case of get exception error
---
Modified: src/modules/app_python/python_support.c
---
Diff:
https://github.com/kamailio/kamailio/commit/dc00778decd5a7c91208fb1ae31d875…
Patch:
https://github.com/kamailio/kamailio/commit/dc00778decd5a7c91208fb1ae31d875…
---
diff --git a/src/modules/app_python/python_support.c
b/src/modules/app_python/python_support.c
index 57a14d0b08..b48bf2c8b3 100644
--- a/src/modules/app_python/python_support.c
+++ b/src/modules/app_python/python_support.c
@@ -54,6 +54,7 @@ void python_handle_exception(const char *fmt, ...)
PyErr_Clear();
if (exception == NULL) {
LM_ERR("Can't get traceback, PyErr_Fetch() has failed.\n");
+ if (srcbuf) pkg_free(srcbuf);
return;
}