[Asterisk-Users] Re: exten => *0. not possible

Tony Mountifield tony at softins.clara.co.uk
Mon May 22 07:39:28 MST 2006


In article <1148307369.23737.17.camel at guru.puzzled.xs4all.nl>,
Patrick <asterisk at puzzled.xs4all.nl> wrote:
> Hi all,
> 
> It seems that using exten => _*0. is not possible in extensions.conf. I
> changed disconnect => *0 in features.conf to something else. From what I
> can tell with the little C knowledge I have is that it's caused by a
> hardcoded *0 value chan_zap.c.
> 
> Line 5730 of chan_zap.c (svn rev 1077) shows:
> 
> } else if (!strcmp(exten, "*0")) {
> 	struct ast_channel *nbridge = 
> 		p->subs[SUB_THREEWAY].owner;
> 	struct zt_pvt *pbridge = NULL;
> 
> Can I just change that value to something else like *999999999 or even
> totally remove the code so I can use exten => _*0. in my dialplan?
> 
> I'd also appreciate some guidance how to go about removing all the
> hardcoded US service codes from chan_zap.c so those values become
> available for dialplan sourcery.

Hi Patrick,

Are you using analogue phones connected to your asterisk box (directly
or through a channel bank)? Because it looks from the code as if that
is the only situation where those codes are captured by the chan_zap
driver and processed specially.

If you want to disable them, just insert an 'x' into the string, or some
other non-DTMF character. Then the strcmp will never match:

} else if (!strcmp(exten, "x*0")) {

Cheers
Tony
-- 
Tony Mountifield
Work: tony at softins.co.uk - http://www.softins.co.uk
Play: tony at mountifield.org - http://tony.mountifield.org



More information about the asterisk-users mailing list