summaryrefslogtreecommitdiff
path: root/res/res_convert.c
diff options
context:
space:
mode:
authorCorey Farrell <git@cfware.com>2015-05-04 17:41:08 -0400
committerCorey Farrell <git@cfware.com>2015-05-04 20:47:18 -0400
commitdf6c1d755f39308c77f3c49ef0f5fa539e627330 (patch)
tree21f12dd8173c44ce1caa6f3797be062910db2b55 /res/res_convert.c
parenta8bfa9e10445744581d18819c64729844ae837fb (diff)
CLI: Enable automatic references to modules.
* Pass module to ast_cli_register and ast_cli_register_multiple. * Add a module reference before executing any CLI callback, remove the reference when complete. ASTERISK-25049 #close Reported by: Corey Farrell Change-Id: I7aafc7c9f2b912918f28fe51d51e9e8a755750e3
Diffstat (limited to 'res/res_convert.c')
-rw-r--r--res/res_convert.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/res/res_convert.c b/res/res_convert.c
index 2a691a56a..3ca596511 100644
--- a/res/res_convert.c
+++ b/res/res_convert.c
@@ -88,9 +88,6 @@ static char *handle_cli_file_convert(struct ast_cli_entry *e, int cmd, struct as
return NULL;
}
- /* ugly, can be removed when CLI entries have ast_module pointers */
- ast_module_ref(ast_module_info->self);
-
if (a->argc != 4 || ast_strlen_zero(a->argv[2]) || ast_strlen_zero(a->argv[3])) {
ret = CLI_SHOWUSAGE;
goto fail_out;
@@ -142,8 +139,6 @@ fail_out:
if (fs_in)
ast_closestream(fs_in);
- ast_module_unref(ast_module_info->self);
-
return ret;
}