[asterisk-users] Gosub behavior change <=1.6.0.5 to 1.6.0.6
Klaus Darilion
klaus.mailinglists at pernau.at
Tue Feb 24 16:07:52 CST 2009
Barry L. Kline wrote:
> -----BEGIN PGP SIGNED MESSAGE-----
> Hash: SHA1
>
> Here's one that may be of interest to any upgraders. If you rely on the
> behavior of gosub you may want to make note of this change.
>
> I have an incoming call context:
>
> exten => _XXXX,n,GoSub(incoming,${EXTEN},1(${EXTEN}));
>
> that is supposed to gosub into the incoming extension at priority 1.
> Versions before 1.6.0.6 would drop into the incoming,i,1 priority if the
> requested extension wasn't present in the incoming context.
>
> When I upgraded to 1.6.0.6 this behavior changed and I would simply get
> an error on the console that a matching extension was not found, and the
> dialplan would simply stop. It was easy enough to add:
>
> [incoming]
> exten => _XXXX,1,Goto(i,1)
>
> to restore the previous behavior (I'm looking at four-digits from a PRI)
> which I should probably have done anyway.
>
> I don't know if this is a bug or WAD but just wanted to mention it.
That's probably related to a bug I reported. The i extension did match
when the Gosub was executed normally, but now when the Gosub was
executed from within a macro. I reported that they should fix the macro
case - obviously they implemented the "bug" also in the normal case.
Nevertheless you can workaround it by using e.g. _[0-9]. instead of i
Really strange that Goto and Gosub behave different.
regards
klaus
More information about the asterisk-users
mailing list