[asterisk-dev] Applicationmap and multiple Key/ActivatedBy entries.

Atis atis at BEST.eu.org
Tue Sep 18 04:31:46 CDT 2007


On 9/17/07, Russell Bryant <russell at digium.com> wrote:
> Atis wrote:
> > [applicationmap]
> > nway_start_target => 00,self/callee,Macro,nway_start
> > nway_start_source => 00,self/caller,Macro,nway_start
>
> <snip>
>
> > if (!strcmp(feature->exten, code)) {
> >   if (option_verbose > 2)
> >     ast_verbose(VERBOSE_PREFIX_3 " Feature Found: %s exten:
> > %s\n",feature->sname, tok);
> >   res = feature->operation(chan, peer, config, code, sense, feature);
> >   AST_LIST_UNLOCK(&feature_list);
> >   break;
> >
> > So, it just calls first feature and activatedby checking is done
> > inside. I would be willing to play with this, but my C experience is
> > quite limited. So, how should this be best done - create function for
> > checking that feature can be used, and do operation() only then. Or
> > check some result codes of operation() (for now i got 21 and 23 - they
> > are meaningless to me).
>
> I would consider this a valid bug.  In the case that the feature doesn't execute
> because of the activated on/by setting, it should return a result that indicates
> that the code should keep trying other features for a match.
>
> I went ahead and just fixed it.  See 1.4 and trunk revisions 82594 and 82595.
>
> Thank you for describing the problem extremely well!

Thanks, it seems working.

Regards,
Atis

-- 
Atis Lezdins,
IT Responsible of BEST Riga,
atis at BEST.eu.org
ICQ: 142239285
Skype: atis.lezdins
Cell Phone: +371 28806004 [Tele2, Latvia]
Work phone: +1 800 7502835 [Toll free, USA]
?BEST? -> www.BEST.eu.org



More information about the asterisk-dev mailing list