Allow early media (SDP in 1xx messages) to change the formats list.

git-svn-id: http://voip.null.ro/svn/yate@1979 acf43c95-373e-0410-b603-e72c3f656dc1
This commit is contained in:
paulc 2008-05-10 17:17:11 +00:00
parent bc74eefad4
commit 115f88d2eb
2 changed files with 7 additions and 0 deletions

View File

@ -173,3 +173,6 @@
; ignore_missing_ack: bool: Ignore missing ACK on INVITE, don't drop the calls
;ignore_missing_ack=no
; 1xx_change_formats: bool: Provisional messages can change the formats list
;1xx_change_formats=yes

View File

@ -576,6 +576,7 @@ static bool s_rfc2833 = true;
static bool s_forward_sdp = false;
static bool s_start_rtp = false;
static bool s_ack_required = true;
static bool s_1xx_formats = true;
static bool s_auth_register = true;
static bool s_multi_ringing = false;
static bool s_refresh_nosdp = true;
@ -2406,6 +2407,8 @@ MimeSdpBody* YateSIPConnection::createProvisionalSDP(Message& msg)
return 0;
if (m_rtpAddr.null())
return 0;
if (s_1xx_formats)
updateFormats(msg);
return createRtpSDP(true);
}
@ -4517,6 +4520,7 @@ void SIPDriver::initialize()
s_auth_register = s_cfg.getBoolValue("registrar","auth_required",true);
s_nat_refresh = s_cfg.getIntValue("registrar","nat_refresh",25);
s_ack_required = !s_cfg.getBoolValue("hacks","ignore_missing_ack",false);
s_1xx_formats = s_cfg.getBoolValue("hacks","1xx_change_formats",true);
initAudioCodecs();
if (!m_endpoint) {
m_endpoint = new YateSIPEndPoint();