diff options
author | Tilghman Lesher <tilghman@meg.abyt.es> | 2007-06-06 21:20:11 +0000 |
---|---|---|
committer | Tilghman Lesher <tilghman@meg.abyt.es> | 2007-06-06 21:20:11 +0000 |
commit | 9d05ff8ed5f2c898370896ff7a8bb67885596ba1 (patch) | |
tree | 5503cb153c9de46c07e3a0a521cc996926ed375b /main/enum.c | |
parent | 033a3df22aa68f04327066e0567b76f73c437651 (diff) |
Issue 9869 - replace malloc and memset with ast_calloc, and other coding guidelines changes
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@67864 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'main/enum.c')
-rw-r--r-- | main/enum.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/main/enum.c b/main/enum.c index 140a38ff9..a860dcb4c 100644 --- a/main/enum.c +++ b/main/enum.c @@ -443,7 +443,7 @@ int ast_get_enum(struct ast_channel *chan, const char *number, char *dst, int ds } if (chan && ast_autoservice_start(chan) < 0) { - free(context); + ast_free(context); return -1; } @@ -523,11 +523,11 @@ int ast_get_enum(struct ast_channel *chan, const char *number, char *dst, int ds if (!argcontext) { for (k = 0; k < context->naptr_rrs_count; k++) { - free(context->naptr_rrs[k].result); - free(context->naptr_rrs[k].tech); + ast_free(context->naptr_rrs[k].result); + ast_free(context->naptr_rrs[k].tech); } - free(context->naptr_rrs); - free(context); + ast_free(context->naptr_rrs); + ast_free(context); } else *argcontext = context; @@ -622,7 +622,7 @@ int ast_enum_init(void) while (s) { sl = s; s = s->next; - free(sl); + ast_free(sl); } toplevs = NULL; cfg = ast_config_load("enum.conf"); |