[asterisk-commits] mjordan: branch 13 r431600 - /branches/13/res/res_pjsip_sdp_rtp.c

SVN commits to the Asterisk project asterisk-commits at lists.digium.com
Sun Feb 8 11:24:09 CST 2015


Author: mjordan
Date: Sun Feb  8 11:24:01 2015
New Revision: 431600

URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=431600
Log:
res/res_pjsip_sdp_rtp: Fix leak of local ICE candidates when applying to SDP

When an SDP is created for an outgoing request/response, the ICE candidates
obtained from the RTP instance are currently leaked. This causes the ao2
container that holds the candidates to never properly be reclaimed when the
RTP instance is destroyed.

This patch properly decrements the ICE candidates' container if it is
successfully obtained.

ASTERISK-24769 #close
Reported by: Matt Jordan

Modified:
    branches/13/res/res_pjsip_sdp_rtp.c

Modified: branches/13/res/res_pjsip_sdp_rtp.c
URL: http://svnview.digium.com/svn/asterisk/branches/13/res/res_pjsip_sdp_rtp.c?view=diff&rev=431600&r1=431599&r2=431600
==============================================================================
--- branches/13/res/res_pjsip_sdp_rtp.c (original)
+++ branches/13/res/res_pjsip_sdp_rtp.c Sun Feb  8 11:24:01 2015
@@ -396,6 +396,7 @@
 	}
 
 	ao2_iterator_destroy(&it_candidates);
+	ao2_ref(candidates, -1);
 }
 
 /*! \brief Function which processes ICE attributes in an audio stream */




More information about the asterisk-commits mailing list