Selaa lähdekoodia

pike: export MI commands

- MI commands exported from mod_init
- MI API is now a library (lib/kmi), SR core does not call anymore
  register_mi_mod(...)
Daniel-Constantin Mierla 16 vuotta sitten
vanhempi
commit
6635cb9f70
1 muutettua tiedostoa jossa 6 lisäystä ja 0 poistoa
  1. 6 0
      modules_k/pike/pike.c

+ 6 - 0
modules_k/pike/pike.c

@@ -110,6 +110,12 @@ struct module_exports exports= {
 
 
 static int pike_init(void)
 static int pike_init(void)
 {
 {
+	if(register_mi_mod(exports.name, mi_cmds)!=0)
+	{
+		LM_ERR("failed to register MI commands\n");
+		return -1;
+	}
+
 	/* alloc the timer lock */
 	/* alloc the timer lock */
 	timer_lock=lock_alloc();
 	timer_lock=lock_alloc();
 	if (timer_lock==0) {
 	if (timer_lock==0) {