aboutsummaryrefslogtreecommitdiffstats
path: root/udptl.c
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2006-06-24 04:03:52 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2006-06-24 04:03:52 +0000
commit00bdf96fdec206e6154056f57324a21542074af0 (patch)
tree7fa7bad4e7a773b4e62f03a5a00e82455966bc88 /udptl.c
parenteb369cb54f132925a4890fc1434b385d57df02ca (diff)
ast_calloc, instead of malloc and memset
git-svn-id: http://svn.digium.com/svn/asterisk/trunk@35788 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'udptl.c')
-rw-r--r--udptl.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/udptl.c b/udptl.c
index a7c6e8a45..86fa42b5c 100644
--- a/udptl.c
+++ b/udptl.c
@@ -772,9 +772,8 @@ struct ast_udptl *ast_udptl_new_with_bindaddr(struct sched_context *sched, struc
int i;
long int flags;
- if ((udptl = malloc(sizeof(struct ast_udptl))) == NULL)
+ if (!(udptl = ast_calloc(1, sizeof(*udptl))))
return NULL;
- memset(udptl, 0, sizeof(struct ast_udptl));
if (udptlfectype == 2)
udptl->error_correction_scheme = UDPTL_ERROR_CORRECTION_FEC;