aboutsummaryrefslogtreecommitdiffstats
path: root/cel
diff options
context:
space:
mode:
authorseanbright <seanbright@f38db490-d61c-443f-a65b-d21fe96a405b>2010-01-15 18:21:50 +0000
committerseanbright <seanbright@f38db490-d61c-443f-a65b-d21fe96a405b>2010-01-15 18:21:50 +0000
commitadc69e041d2b415b3422672fb262423808dfa8ab (patch)
treeede1629dadd9e525779f3da8f54510a9dd1ea081 /cel
parenta79e0451bce168a451e7ed1e30226166e58e203c (diff)
Convert a few places to use ast_calloc_with_stringfields where applicable.
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@240368 f38db490-d61c-443f-a65b-d21fe96a405b
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;
}