OPENZAP-28 pass opts from mod_openzap to ozmod_isdn

git-svn-id: http://svn.openzap.org/svn/openzap/trunk@589 a93c3328-9c30-0410-af19-c9cd2b2d52af
This commit is contained in:
Anthony Minessale 2008-10-07 15:27:51 +00:00
parent 540ac84710
commit f1e9611fd1
3 changed files with 9 additions and 6 deletions

View File

@ -1893,6 +1893,7 @@ static switch_status_t load_config(void)
if (zap_configure_span("isdn", span, on_clear_channel_signal,
"mode", mode,
"dialect", dialect,
"opts", opts,
"q921loglevel", q921loglevel,
"q931loglevel", q931loglevel,
TAG_END) != ZAP_SUCCESS) {

View File

@ -1726,11 +1726,11 @@ static ZIO_SIG_CONFIGURE_FUNCTION(zap_isdn_configure_span)
dialect = Q931_Dialect_National;
}
} else if (!strcasecmp(var, "opts")) {
int *optp;
if (!(optp = va_arg(ap, int *))) {
break;
}
opts = isdn_data->opts = *optp;
opts = va_arg(ap, uint32_t);
if (opts >= ZAP_ISDN_OPT_MAX) {
return ZAP_FAIL;
}
isdn_data->opts = opts;
} else if (!strcasecmp(var, "tonemap")) {
if (!(val = va_arg(ap, char *))) {
break;

View File

@ -37,7 +37,9 @@
typedef enum {
ZAP_ISDN_OPT_NONE = 0,
ZAP_ISDN_OPT_SUGGEST_CHANNEL = (1 << 0)
ZAP_ISDN_OPT_SUGGEST_CHANNEL = (1 << 0),
ZAP_ISDN_OPT_MAX = (2 << 0)
} zap_isdn_opts_t;
typedef enum {