Module: kamailio
Branch: master
Commit: 988cc68d62b8a00a69786e43f99417c05572aef6
URL:
https://github.com/kamailio/kamailio/commit/988cc68d62b8a00a69786e43f99417c…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2018-03-10T08:21:20+01:00
app_python: skip execution of child_init() for rank PROC_INIT
- this is a particular execution in main process after all modules were
initialized, not in a forked child process
---
Modified: src/modules/app_python/app_python_mod.c
---
Diff:
https://github.com/kamailio/kamailio/commit/988cc68d62b8a00a69786e43f99417c…
Patch:
https://github.com/kamailio/kamailio/commit/988cc68d62b8a00a69786e43f99417c…
---
diff --git a/src/modules/app_python/app_python_mod.c
b/src/modules/app_python/app_python_mod.c
index 3f5463bd0a..5c5278f42d 100644
--- a/src/modules/app_python/app_python_mod.c
+++ b/src/modules/app_python/app_python_mod.c
@@ -174,6 +174,9 @@ static int mod_init(void)
*/
static int child_init(int rank)
{
+ if(rank==PROC_INIT) {
+ return 0;
+ }
_apy_process_rank = rank;
PyOS_AfterFork();
return apy_init_script(rank);