[Home]

Summary:ASTERISK-09676: Channel variable ${SLATRUNK_STATUS} returns SUCCESS on ringtimeout and on answered conditions.
Reporter:Chris Craft (n00dle)Labels:
Date Opened:2007-06-13 17:27:33Date Closed:2007-06-15 10:36:51
Priority:MinorRegression?No
Status:Closed/CompleteComponents:Applications/SLA
Versions:Frequency of
Occurrence
Related
Issues:
Environment:Attachments:( 0) cdc20070613.patch
Description:When the application SLATRUNK() returns, the channel variable ${SLATRUNK_STATUS} contains SUCCESS on ringtimeout and on answered conditions.  Trying to determine whether to send to Voicemail or not becomes difficult.  

****** ADDITIONAL INFORMATION ******

I have a workaround, patch uploaded with this report.  Sets different variables when each of the conditions terminating the app occur; not pretty but I can use it to see if a call needs voicemail or not.  My (ugly) version of [macro-slaline] is below:
[macro-slaline]
; This macro has been modified from the sla.pdf version to allow
;   for sending calls from different trunks to different voice
;   mailboxes
;exten => s,1,Answer(${ARG1})
exten => s,1,SLATrunk(${ARG1})
exten => s,2,noop(${CALLERID(num)} ${CALLERID(name)} ${SLATRUNK_STATUS})
exten => s,3,noop(${SLATRUNK_TIMEDOUT} ${SLATRUNK_ANSWERED})
exten => s,4,GotoIf($["${SLATRUNK_TIMEDOUT}" = "TIMEDOUT"]?s-UNANSWERED:5)
exten => s,5,GotoIf($["${SLATRUNK_ANSWERED}" = "ANSWERED"]?7:6)
exten => s,6,Goto(s-${SLATRUNK_STATUS}|1)
exten => s,7,Hangup()
exten => s-SUCCESS,1,Hangup()
exten => s-FAILURE,1,Voicemail(${ARG2}|u)
exten => s-UNANSWERED,1,Voicemail(${ARG2}|u)
Comments:By: Chris Craft (n00dle) 2007-06-13 20:19:06

If you got my old patch, don't use it... I inadvertently introduced a crash... much badness...

By: Leif Madsen (lmadsen) 2007-06-13 20:26:20

File removed as per request on IRC

By: Russell Bryant (russell) 2007-06-15 10:36:50

The SLATRUNK_STATUS variable should now indicate RINGTIMEOUT on a ring timeout.  This is in 1.4 and trunk in revisions 69519 and 69518.  Thanks!