[asterisk-bugs] [JIRA] (ASTERISK-26343) ASTERISK-25951 causes issues for callerid manipulation through agi

Mark Michelson (JIRA) noreply at issues.asterisk.org
Wed Nov 2 12:41:10 CDT 2016


    [ https://issues.asterisk.org/jira/browse/ASTERISK-26343?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=233340#comment-233340 ] 

Mark Michelson commented on ASTERISK-26343:
-------------------------------------------

Based on the change that introduced the problem, I think the issue is that a connected line frame is being deferred until after the AGI completes. That connected line frame is overwriting the caller ID change you made on the channel.

I'll try to devise some way to fix this.

> ASTERISK-25951 causes issues for callerid manipulation through agi
> ------------------------------------------------------------------
>
>                 Key: ASTERISK-26343
>                 URL: https://issues.asterisk.org/jira/browse/ASTERISK-26343
>             Project: Asterisk
>          Issue Type: Bug
>      Security Level: None
>          Components: Resources/res_agi
>    Affects Versions: 13.11.0
>            Reporter: Morten Tryfoss
>            Assignee: Mark Michelson
>
> ASTERISK-25951 seems to change behaviour for agi scripts. Tested with the old version, and everything seems to work as before. Setting callerid through dialplan works ok.
> Consider this configuration:
> [test2]
> exten => 1,1,agi(test.agi) 
> exten => 1,n,Hangup
> [test1]
> exten => 1,1,agi(test.agi) 
> exten => 1,n,Dial(Local/1 at test2/n)
> exten => 1,n,Hangup
> [default]
> exten => 94013213,1,set(__TRANSFER_CONTEXT=test1)
> exten => 94013213,n,Dial(SIP/bnsip3/person_1_6_fixed,,t)
> exten => 94013213,n,Hangup
> Call enters default context and user does attended transfer to extension 1 in [test1].
> Now see the agi debug and my comments:
> first channel:
> read: agi_request: test.agi
> read: agi_channel: Local/1 at test1-00000006;2
> read: agi_language: no
> read: agi_type: Local
> read: agi_uniqueid: 1473239189.21
> read: agi_version: 13.11.0
> read: agi_callerid: 94013213
> read: agi_calleridname: unknown
> read: agi_callingpres: 0
> read: agi_callingani2: 0
> read: agi_callington: 0
> read: agi_callingtns: 0
> read: agi_dnid: unknown
> read: agi_rdnis: unknown
> read: agi_context: test1
> read: agi_extension: 1
> read: agi_priority: 1
> read: agi_enhanced: 0.0
> read: agi_accountcode: 
> read: agi_threadid: 139664920155904
> read: 
> write: GET VARIABLE CALLERID(number)
> read: 200 result=1 (94013213)
> write: SET VARIABLE "CALLERID(number)" "44444444" <---- Callerid is changed here
> read: 200 result=1
> write: GET VARIABLE CALLERID(number) <------- New value
> read: 200 result=1 (44444444)
> write: GET VARIABLE TESTVAR
> read: 200 result=0
> write: SET VARIABLE "__TESTVAR" "12346789"
> read: 200 result=1
> write: GET VARIABLE TESTVAR
> read: 200 result=1 (12346789)
> Second channel:
> read: agi_request: test.agi
> read: agi_channel: Local/1 at test2-00000007;2
> read: agi_language: no
> read: agi_type: Local
> read: agi_uniqueid: 1473239189.23
> read: agi_version: 13.11.0
> read: agi_callerid: 44444444 <-- Has the correct new value on script start.
> read: agi_calleridname: unknown
> read: agi_callingpres: 0
> read: agi_callingani2: 0
> read: agi_callington: 0
> read: agi_callingtns: 0
> read: agi_dnid: unknown
> read: agi_rdnis: unknown
> read: agi_context: test2
> read: agi_extension: 1
> read: agi_priority: 1
> read: agi_enhanced: 0.0
> read: agi_accountcode: 
> read: agi_threadid: 139664915076864
> read: 
> write: GET VARIABLE CALLERID(number) <---- This still contrains the OLD value. It is not changed from script starts to here.
> read: 200 result=1 (94013213)
> write: SET VARIABLE "CALLERID(number)" "44444444"
> read: 200 result=1
> write: GET VARIABLE CALLERID(number)
> read: 200 result=1 (44444444)
> write: GET VARIABLE TESTVAR
> read: 200 result=1 (12346789)
> write: SET VARIABLE "__TESTVAR" "12346789"
> read: 200 result=1
> write: GET VARIABLE TESTVAR
> read: 200 result=1 (12346789)



--
This message was sent by Atlassian JIRA
(v6.2#6252)



More information about the asterisk-bugs mailing list