From: Matthew Jordan Date: Sat, 29 Sep 2012 03:54:15 +0000 (+0000) Subject: Fix ref leak when adding ICE candidates to an SDP X-Git-Tag: 11.0.0-rc1~25 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=30d590a97046c5d1ad983ea4be0914ea820381a7;p=thirdparty%2Fasterisk.git Fix ref leak when adding ICE candidates to an SDP There was a missing decrement to the reference count for the current ICE candidate when local candidates are being added to an outbound SDP. This patch corrects that. git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/11@374085 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/channels/chan_sip.c b/channels/chan_sip.c index 3ea82188f0..3eb55946cf 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -12198,6 +12198,7 @@ static void add_ice_to_sdp(struct ast_rtp_instance *instance, struct ast_str **a } ast_str_append(a_buf, 0, "\r\n"); + ao2_ref(candidate, -1); } ao2_iterator_destroy(&i);