From: Joshua Colp Date: Tue, 7 Aug 2012 17:47:52 +0000 (+0000) Subject: Fix a bug uncovered by the test suite where the RTP payload number was not getting... X-Git-Tag: 11.0.0-beta1~34 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=da808a0b6616a5af3df16d108858061720fbaef0;p=thirdparty%2Fasterisk.git Fix a bug uncovered by the test suite where the RTP payload number was not getting set. git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@370845 65c4cc65-6c06-0410-ace0-fbb531ad65f3 --- diff --git a/main/rtp_engine.c b/main/rtp_engine.c index 46b75be727..7907efba45 100644 --- a/main/rtp_engine.c +++ b/main/rtp_engine.c @@ -590,10 +590,12 @@ int ast_rtp_codecs_payloads_set_rtpmap_type_rate(struct ast_rtp_codecs *codecs, if (!(type = ao2_alloc(sizeof(*type), NULL))) { continue; } + type->rtp_code = pt; ao2_link_flags(codecs->payloads, type, OBJ_NOLOCK); } *type = t->payload_type; + type->rtp_code = pt; if ((t->payload_type.format.id == AST_FORMAT_G726) && t->payload_type.asterisk_format && (options & AST_RTP_OPT_G726_NONSTANDARD)) { ast_format_set(&type->format, AST_FORMAT_G726_AAL2, 0);