[asterisk-dev] [asterisk-commits] mattf: trunk r150640 - in /trunk: channels/ configs/
Matthew Fredrickson
creslin at digium.com
Mon Oct 20 11:58:01 CDT 2008
Kevin P. Fleming wrote:
> SVN commits to the Asterisk project wrote:
>
>> +#ifdef PRI_SET_CHAN_MAPPING_LOGICAL
>> + pri_set_chan_mapping_logical(pri->dchans[i], pri->qsigchannelmapping == DAHDI_CHAN_MAPPING_LOGICAL);
>> +#endif
>
> Please use a configure script check to determine whether this
> functionality is available or not, rather than adding more #define
> statements to libpri.h. This should also be done for the
> discardremotehold feature.
>
>> #ifdef HAVE_PRI_INBANDDISCONNECT
>> + } else if (!strcasecmp(v->name, "qsigchannelmapping")) {
>> + if (!strcasecmp(v->value, "logical")) {
>> + confp->pri.qsigchannelmapping = DAHDI_CHAN_MAPPING_LOGICAL;
>> + } else if (!strcasecmp(v->value, "physical")) {
>> + confp->pri.qsigchannelmapping = DAHDI_CHAN_MAPPING_PHYSICAL;
>> + } else {
>> + confp->pri.qsigchannelmapping = DAHDI_CHAN_MAPPING_PHYSICAL;
>> + }
>> + } else if (!strcasecmp(v->name, "discardremoteholdretrieval")) {
>> + confp->pri.discardremoteholdretrieval = ast_true(v->value);
>
> This code does not belong inside the HAVE_PRI_INBANDDISCONNECT
> condition. Also, please report an error with LOG_ERROR if the value
> supplied for qsigchannelmapping is invalid.
As long as we're backing these checks out, it would also make sense to
remove the old HAVE_PRI_INBANDDISCONNECT check as well...
Matthew Fredrickson
Digium, Inc.
More information about the asterisk-dev
mailing list