Module: kamailio Branch: master Commit: 17a33388138c2510e9e483c0526948772a1478f4 URL: https://github.com/kamailio/kamailio/commit/17a33388138c2510e9e483c0526948772a1478f4
Author: Daniel-Constantin Mierla <mico...@gmail.com> Committer: Daniel-Constantin Mierla <mico...@gmail.com> Date: 2018-08-20T11:11:45+02:00 app_python: init cfg vars framework only in child init - apy init is executed in other parts as well --- Modified: src/modules/app_python/app_python_mod.c --- Diff: https://github.com/kamailio/kamailio/commit/17a33388138c2510e9e483c0526948772a1478f4.diff Patch: https://github.com/kamailio/kamailio/commit/17a33388138c2510e9e483c0526948772a1478f4.patch --- diff --git a/src/modules/app_python/app_python_mod.c b/src/modules/app_python/app_python_mod.c index 8ed21e1c93..6535cd93b3 100644 --- a/src/modules/app_python/app_python_mod.c +++ b/src/modules/app_python/app_python_mod.c @@ -180,6 +180,9 @@ static int child_init(int rank) } _apy_process_rank = rank; PyOS_AfterFork(); + if (cfg_child_init()) { + return -1; + } return apy_init_script(rank); } @@ -436,10 +439,6 @@ int apy_init_script(int rank) goto err; } - if (cfg_child_init()) { - goto err; - } - pArgs = PyTuple_New(1); if (pArgs == NULL) { python_handle_exception("child_init"); _______________________________________________ Kamailio (SER) - Development Mailing List sr-dev@lists.kamailio.org https://lists.kamailio.org/cgi-bin/mailman/listinfo/sr-dev