Set the latest message in SIP client transactions. Compute user timeout from standard SIP timers.

git-svn-id: http://voip.null.ro/svn/yate@2442 acf43c95-373e-0410-b603-e72c3f656dc1
This commit is contained in:
paulc 2009-01-16 14:59:27 +00:00
parent 8f106b1639
commit 1e30af892e
3 changed files with 5 additions and 3 deletions

View File

@ -322,8 +322,8 @@ void SIPEngine::processEvent(SIPEvent *event)
u_int64_t SIPEngine::getUserTimeout() const
{
// by default allow 2 minutes for user interaction
return 120000000;
// by default allow almost 3 minutes (proxy INVITE) for user interaction
return getTimer('C') - getTimer('2');
}
u_int64_t SIPEngine::getTimer(char which, bool reliable) const

View File

@ -533,6 +533,7 @@ void SIPTransaction::processClientMessage(SIPMessage* message, int state)
case Process:
if (message->code <= 100)
break;
setLatestMessage(message);
if (tryAutoAuth(message))
break;
if (m_invite && !final)

View File

@ -971,7 +971,8 @@ public:
/**
* Get the timeout to be used for transactions involving human interaction.
* The default implementation returns 120000000 (2 minutes)
* The default implementation returns the proxy INVITE timeout (timer C = 3 minutes)
* minus the INVITE response retransmit interval (timer T2 = 4 seconds)
* @return Duration of the timeout in microseconds
*/
virtual u_int64_t getUserTimeout() const;