nua_handle_t *nua_stack_handle_by_call_id(nua_t *nua, const char *call_id) { if (nua) { nta_leg_t *leg = nta_leg_by_call_id(nua->nua_nta, call_id); if (leg) return nta_leg_magic(leg, nua_stack_process_request); } return NULL; }
SipDialog::~SipDialog() { DR_LOG(log_debug) << "SipDialog::~SipDialog - destroying sip dialog with call-id " << getCallId() ; if( NULL != m_timerSessionRefresh ) { cancelSessionTimer() ; assert( m_ppSelf ) ; } if( m_ppSelf ) { delete m_ppSelf ; } nta_leg_t *leg = nta_leg_by_call_id( theOneAndOnlyController->getAgent(), getCallId().c_str() ); assert( leg ) ; if( leg ) { nta_leg_destroy( leg ) ; } }