summaryrefslogtreecommitdiff
path: root/cel
diff options
context:
space:
mode:
authorSean Bright <sean@malleable.com>2010-01-15 18:21:50 +0000
committerSean Bright <sean@malleable.com>2010-01-15 18:21:50 +0000
commite612d87695ec794059dfe3fc0021bd11a331713d (patch)
treeede1629dadd9e525779f3da8f54510a9dd1ea081 /cel
parent89413e9ae2d8f0105758c5007313d60c540a8253 (diff)
Convert a few places to use ast_calloc_with_stringfields where applicable.
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@240368 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'cel')
-rw-r--r--cel/cel_tds.c8
1 files changed, 2 insertions, 6 deletions
diff --git a/cel/cel_tds.c b/cel/cel_tds.c
index 138a9cdd3..631c3cb96 100644
--- a/cel/cel_tds.c
+++ b/cel/cel_tds.c
@@ -541,13 +541,9 @@ static int load_module(void)
dberrhandle(tds_error_handler);
dbmsghandle(tds_message_handler);
- settings = ast_calloc(1, sizeof(*settings));
+ settings = ast_calloc_with_stringfields(1, struct cel_tds_config, 256);
- if (!settings || ast_string_field_init(settings, 256)) {
- if (settings) {
- ast_free(settings);
- settings = NULL;
- }
+ if (!settings) {
dbexit();
return AST_MODULE_LOAD_DECLINE;
}