aboutsummaryrefslogtreecommitdiffstats
path: root/channels/chan_jingle.c
diff options
context:
space:
mode:
authorrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2006-06-18 21:24:35 +0000
committerrussell <russell@f38db490-d61c-443f-a65b-d21fe96a405b>2006-06-18 21:24:35 +0000
commitafea7adc1ccd2ed6a3dd1607d2f425cccfbd08ed (patch)
tree03653b3d5b48a70c03f0ab06eb893ef40c513256 /channels/chan_jingle.c
parent4dd4cc3eecc6434d5d487eb4bd084dad3d4e9d88 (diff)
bail if ast_calloc fails, this was done before but i accidently removed it when
moving these allocations so duplicate error messages were not produced (issue #7345) git-svn-id: http://svn.digium.com/svn/asterisk/trunk@34663 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels/chan_jingle.c')
-rw-r--r--channels/chan_jingle.c2
1 files changed, 2 insertions, 0 deletions
diff --git a/channels/chan_jingle.c b/channels/chan_jingle.c
index a5c649ec7..16bd521da 100644
--- a/channels/chan_jingle.c
+++ b/channels/chan_jingle.c
@@ -536,6 +536,8 @@ static int jingle_create_candidates(struct jingle *client, struct jingle_pvt *p,
}
ours1 = ast_calloc(1, sizeof(*ours1));
ours2 = ast_calloc(1, sizeof(*ours2));
+ if (!ours1 || !ours2)
+ goto safeout;
iks_insert_node(iq, jingle);
iks_insert_node(jingle, candidate);