diff -r 1bce908db942 -r 966b25fd74b5 multimediacommsengine/mmcesrv/mmceserver/src/mcesipsession.cpp --- a/multimediacommsengine/mmcesrv/mmceserver/src/mcesipsession.cpp Tue Feb 02 01:04:58 2010 +0200 +++ b/multimediacommsengine/mmcesrv/mmceserver/src/mcesipsession.cpp Fri Mar 19 09:37:25 2010 +0200 @@ -225,6 +225,13 @@ CMceComSession* body = iBodyBucket[ 0 ]; if ( &body->SdpSession() ) { + if( body->SdpSession().Context() == Dialog() ) + { + //fork situation + CMceComSession* tmpBody = body; + body = iBody; + iBody = tmpBody; + } body->SdpSession().AttachContext( NULL ); } CMceComSession::Delete( body, Manager().MediaManager() ); @@ -1268,7 +1275,8 @@ } else { - if ( Response().Type() == SIPStrings::StringF( SipStrConsts::EInvite ) ) + if ( Response().Type() == SIPStrings::StringF( SipStrConsts::EInvite ) || + Response().Type() == SIPStrings::StringF( SipStrConsts::EPrack ) ) { // If one of the forked dialogs generated 200 OK response // for a session that is not in established state, @@ -2612,4 +2620,44 @@ { return iForkedDialogs.Count(); } +// ----------------------------------------------------------------------------- +// CMceSipSession::ForceUpdateStreamL +// ----------------------------------------------------------------------------- +// +void CMceSipSession::ForceUpdateStreamL() + { + MCESRV_DEBUG("CMceSipSession::ForceUpdateStream, Entry"); + if( iBody->SdpSession().Context() == Dialog() ) + { + Manager().MediaManager().ForceEnableSinkState( ActiveBody() ); + } + else + { + ActiveBody().SdpSession().UpdateSecureStreamL( ActiveBody() ); + Manager().MediaManager().UpDateStreamStateL( *iBody, ActiveBody() ); + __ASSERT_ALWAYS( iFirstOffer, User::Leave( KErrArgument ) ); + ActiveBody().SdpSession().iSdpDocument = iFirstOffer; + } + MCESRV_DEBUG("CMceSipSession::ForceUpdateStream, Exit"); + } +// ----------------------------------------------------------------------------- +// CMceSipSession::ResetCurrentDialog +// ----------------------------------------------------------------------------- +// +void CMceSipSession::ResetCurrentDialog() + { + if( iBodyBucket.Count() == 0 ) + { + iCurrentDialog = iDialog; + } + } +void CMceSipSession::SetFirstOffer() + { + if( iBodyBucket.Count() == 0 ) + { + CSdpDocument* clonedOffer = NULL; + TRAP_IGNORE( ( clonedOffer = iOffer->CloneL() ) ); + iFirstOffer = clonedOffer; + } + } // End of File