Module: kamailio
Branch: master
Commit: dc00778decd5a7c91208fb1ae31d875677a2b9de
URL: 
https://github.com/kamailio/kamailio/commit/dc00778decd5a7c91208fb1ae31d875677a2b9de

Author: Daniel-Constantin Mierla <[email protected]>
Committer: Daniel-Constantin Mierla <[email protected]>
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/dc00778decd5a7c91208fb1ae31d875677a2b9de.diff
Patch: 
https://github.com/kamailio/kamailio/commit/dc00778decd5a7c91208fb1ae31d875677a2b9de.patch

---

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;
        }
 


_______________________________________________
Kamailio (SER) - Development Mailing List
[email protected]
https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev

Reply via email to