Is Pattern Matching Inside Macro Valid?

Home » Asterisk Users » Is Pattern Matching Inside Macro Valid?
Asterisk Users 1 Comment

Can’t we use pattern matching inside a macro?
Because when I am trying to do so call is terminating even for a very simple dummy dialplan.

[demo3]
exten=>98,1,NoOp()
exten=>98,2,Macro(testme)
exten=>h,1,NoOp(terminating call);

[macro-testme]
exten=>s,1,Playback(Digits/2)
exten=>s,2,WaitExten(15)
exten=>s,3,NoOp()

exten=>_X,1,NoOp(${EXTEN})
exten=>_X,2,Goto(s,3)

Even for this code when execution reaches the line 2 in macro ‘testme’ it terminates as soon as I input some number.

Error :

WARNING[9984][C-0000000d]: pbx.c:6696 __ast_pbx_run: Invalid extension ‘5’, but no rule ‘i’ or ‘e’ in context ‘demo3’
— Executing [h@demo3:1] NoOp(“SIP/101-0000000d”, “terminating call”)
in new stack
[Sep 9 02:11:14] NOTICE[9984]: pbx_spool.c:402 attempt_thread: Call completed to SIP/101/009871888729

Anurag Rana http://newbie42.blogspot.in/

One thought on - Is Pattern Matching Inside Macro Valid?