Browse Source

pdt: 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 năm trước cách đây
mục cha
commit
b30d226e15
1 tập tin đã thay đổi với 6 bổ sung0 xóa
  1. 6 0
      modules_k/pdt/pdt.c

+ 6 - 0
modules_k/pdt/pdt.c

@@ -161,6 +161,12 @@ struct module_exports exports = {
  */
 static int mod_init(void)
 {
+	if(register_mi_mod(exports.name, mi_cmds)!=0)
+	{
+		LM_ERR("failed to register MI commands\n");
+		return -1;
+	}
+
 	db_url.len = strlen(db_url.s);
 	db_table.len = strlen(db_table.s);
 	sdomain_column.len = strlen(sdomain_column.s);