diff options
author | Matthew Jordan <mjordan@digium.com> | 2013-12-21 03:35:04 +0000 |
---|---|---|
committer | Matthew Jordan <mjordan@digium.com> | 2013-12-21 03:35:04 +0000 |
commit | 5a15803a1bee11efc2326cc0c61798d313d8de0b (patch) | |
tree | c0eb2af34dc09daac68ecf115a98f3b54991bad0 /res/res_pjsip/pjsip_cli.c | |
parent | 40a7f68e4ba631515809b9d838e00ae3fc0b5f08 (diff) |
res_pjsip/pjsip_cli: fix compilation error caused by passing ast_free
When wanting to pass *free as a function pointer, ast_free_ptr has to be used
instead of ast_free. This allows it to be compiled with MALLOC_DEBUG enabled.
........
Merged revisions 404531 from http://svn.asterisk.org/svn/asterisk/branches/12
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@404532 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'res/res_pjsip/pjsip_cli.c')
-rw-r--r-- | res/res_pjsip/pjsip_cli.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/res/res_pjsip/pjsip_cli.c b/res/res_pjsip/pjsip_cli.c index 5f8157d2d..45abe0d1a 100644 --- a/res/res_pjsip/pjsip_cli.c +++ b/res/res_pjsip/pjsip_cli.c @@ -20,6 +20,7 @@ #include <pjsip.h> #include <pjsip_ua.h> + #include "asterisk/res_pjsip.h" #include "include/res_pjsip_private.h" #include "asterisk/res_pjsip_cli.h" @@ -303,7 +304,7 @@ int ast_sip_initialize_cli(struct ast_sorcery *sorcery) if (ast_cli_register_multiple(cli_commands, ARRAY_LEN(cli_commands))) { ast_log(LOG_ERROR, "Failed to register pjsip cli commands.\n"); - ast_hashtab_destroy(formatter_registry, ast_free); + ast_hashtab_destroy(formatter_registry, ast_free_ptr); return -1; } sip_sorcery = sorcery; @@ -314,6 +315,6 @@ void ast_sip_destroy_cli(void) { ast_cli_unregister_multiple(cli_commands, ARRAY_LEN(cli_commands)); if (formatter_registry) { - ast_hashtab_destroy(formatter_registry, ast_free); + ast_hashtab_destroy(formatter_registry, ast_free_ptr); } } |