protected void doInitialInviteResponse(SipServletResponse response) throws ServletException, IOException
{
B2buaHelper b2bHelper = response.getRequest().getB2buaHelper();
SipSession leg1 = response.getSession();
SipSession leg2 = b2bHelper.getLinkedSession(leg1);
int status = response.getStatus();
if (leg2 == null)
{
if (status >= SipServletResponse.SC_OK
&& status < SipServletResponse.SC_MULTIPLE_CHOICES)
{
// Create second leg
SipServletRequest request = _sipFactory.createRequest(response.getApplicationSession(),
response.getMethod(),
response.getTo(),
response.getFrom());
copy(response, request);
b2bHelper.linkSipSessions(leg1, request.getSession());
request.setAttribute(RESP_INV, response);
request.getSession().setHandler(getServletName());
// if leg2 took more than 10s to pick up call, cancel it.