mirror of
https://github.com/asterisk/asterisk.git
synced 2025-10-12 07:35:18 +00:00
res_pjsip_session: Delay sending BYE if a re-INVITE transaction is in progress.
Given the scenario where a PJSIP channel is in a native RTP bridge with direct media and the channel is then hung up the code will currently re-INVITE the channel back to Asterisk and send a BYE at the same time. Many SIP implementations dislike this greatly. This change makes it so that if a re-INVITE transaction is in progress the BYE is queued to occur after the completion of the transaction (be it through normal means or a timeout). Review: https://reviewboard.asterisk.org/r/4248/ git-svn-id: https://origsvn.digium.com/svn/asterisk/branches/13@429409 65c4cc65-6c06-0410-ace0-fbb531ad65f3
This commit is contained in:
@@ -433,6 +433,14 @@ struct ast_sip_session *ast_sip_session_create_outgoing(struct ast_sip_endpoint
|
||||
struct ast_sip_contact *contact, const char *location, const char *request_user,
|
||||
struct ast_format_cap *req_caps);
|
||||
|
||||
/*!
|
||||
* \brief Terminate a session and, if possible, send the provided response code
|
||||
*
|
||||
* \param session The session to terminate
|
||||
* \param response The response code to use for termination if possible
|
||||
*/
|
||||
void ast_sip_session_terminate(struct ast_sip_session *session, int response);
|
||||
|
||||
/*!
|
||||
* \brief Defer local termination of a session until remote side terminates, or an amount of time passes
|
||||
*
|
||||
|
Reference in New Issue
Block a user