diff options
author | zuul <zuul@gerrit.asterisk.org> | 2017-03-24 19:21:51 -0500 |
---|---|---|
committer | Gerrit Code Review <gerrit2@gerrit.digium.api> | 2017-03-24 19:21:51 -0500 |
commit | 39fff2ebf9356eaceac6aa0c783a8616cc3b9491 (patch) | |
tree | e72ee654a27c22bde73af1f20ee590af07ca8a8a | |
parent | ddbff36c1259307a27ac2eb72424457f314fc228 (diff) | |
parent | d9d2beba1c0d9aa93382dc4ec8b54627b2a301fa (diff) |
Merge "res_pjsip_sdp_rtp: Set hangup cause for RTP timeouts" into 13
-rw-r--r-- | res/res_pjsip_sdp_rtp.c | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/res/res_pjsip_sdp_rtp.c b/res/res_pjsip_sdp_rtp.c index d44171cf8..52ae65cc7 100644 --- a/res/res_pjsip_sdp_rtp.c +++ b/res/res_pjsip_sdp_rtp.c @@ -163,6 +163,10 @@ static int rtp_check_timeout(const void *data) ast_log(LOG_NOTICE, "Disconnecting channel '%s' for lack of RTP activity in %d seconds\n", ast_channel_name(chan), elapsed); + ast_channel_lock(chan); + ast_channel_hangupcause_set(chan, AST_CAUSE_REQUESTED_CHAN_UNAVAIL); + ast_channel_unlock(chan); + ast_softhangup(chan, AST_SOFTHANGUP_DEV); ast_channel_unref(chan); |