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
This commit is contained in:
Tilghman Lesher
2007-06-06 21:20:11 +00:00
parent 033a3df22a
commit 9d05ff8ed5
94 changed files with 2530 additions and 2701 deletions

View File

@@ -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");