[asterisk-dev] X-Asterisk-HangupCause header only added in auto fallthrough mode

Johansson Olle E oej at edvina.net
Fri Jan 23 03:10:22 CST 2009


23 jan 2009 kl. 09.44 skrev Klaus Darilion:

> Hi!
>
> Is this a bug or a feature I do not understand?
>
> Simple scenario:
>
> ---SIP----> Asterisk ----SIP---->
>         _X. => {
>                 Dial(SIP/${EXTEN});
>         }
>
>
> If the outgoing leg is rejected (e.g. 480), Asterisk will add the
> X-Asterisk-HangupCause headers:
>
>    X-Asterisk-HangupCause: User alerting, no answer
>    X-Asterisk-HangupCauseCode: 19
>
>
> But if the call is hang up manually, these headers are not added:
>         _X. => {
>                 Dial(SIP/${EXTEN});
>                 Hangup(1);  // Hangup() does not work either
>         }
> This causes a SIP response without X-Asterisk-Hangupcause headers.
>
> Why?

A bug. We need to add hangup causes in more places and make sure that  
the
hangupcause headers are always added when needed. In some cases, they're
added when they're not needed now.

Also, we need to add Reason headers too, which are more standards  
compliant.

/O



More information about the asterisk-dev mailing list