Module: sip-router
Branch: 3.1
Commit: 1ad6e142aad3fb4e0229d46dab52ab6ebab7e113
URL:
http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=1ad6e14…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: Sun Apr 10 12:11:07 2011 +0200
uac(k): enable cfg framework for module's extra process
(cherry picked from commit db0a6250180226ffaa700b67018ba25eb5451caf)
---
modules_k/uac/uac.c | 10 ++++++++++
1 files changed, 10 insertions(+), 0 deletions(-)
diff --git a/modules_k/uac/uac.c b/modules_k/uac/uac.c
index 105172d..81dfe35 100644
--- a/modules_k/uac/uac.c
+++ b/modules_k/uac/uac.c
@@ -49,6 +49,7 @@
#include "../../mod_fix.h"
#include "../../rpc.h"
#include "../../rpc_lookup.h"
+#include "../../cfg/cfg_struct.h"
#include "../rr/api.h"
@@ -257,6 +258,8 @@ static int mod_init(void)
}
uac_reg_init_db();
register_procs(1);
+ /* add child to update local config framework structures */
+ cfg_register_child(1);
}
init_from_replacer();
@@ -284,9 +287,16 @@ static int child_init(int rank)
}
if (pid==0){
/* child */
+ /* initialize the config framework */
+ if (cfg_child_init())
+ return -1;
+
uac_reg_load_db();
uac_reg_timer(0);
for(;;){
+ /* update the local config framework structures */
+ cfg_update();
+
sleep(reg_timer_interval);
uac_reg_timer(get_ticks());
}