diff options
author | Richard Mudgett <rmudgett@digium.com> | 2011-09-28 20:28:14 +0000 |
---|---|---|
committer | Richard Mudgett <rmudgett@digium.com> | 2011-09-28 20:28:14 +0000 |
commit | 36a82648928a7df501a2f2447afd748a4870b47d (patch) | |
tree | 5312355f6080d1c60733ba43e123d7990693e601 | |
parent | 659edb7b8fbe6d50c4690d4964ba2dcd772f1175 (diff) |
Merged revisions 338225 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/10
................
r338225 | rmudgett | 2011-09-28 15:26:39 -0500 (Wed, 28 Sep 2011) | 12 lines
Merged revisions 338224 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.8
........
r338224 | rmudgett | 2011-09-28 15:24:41 -0500 (Wed, 28 Sep 2011) | 5 lines
Fix chan_dahd compiling with gcc 4.6 when PRI and SS7 not present.
(closes issue ASTERISK-18357)
Reported by: Matthew Nicholson
........
................
git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@338226 65c4cc65-6c06-0410-ace0-fbb531ad65f3
-rw-r--r-- | channels/chan_dahdi.c | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/channels/chan_dahdi.c b/channels/chan_dahdi.c index a235eaa1c..b26881c43 100644 --- a/channels/chan_dahdi.c +++ b/channels/chan_dahdi.c @@ -12211,7 +12211,9 @@ static struct dahdi_pvt *mkintf(int channel, const struct dahdi_chan_conf *conf, struct dahdi_bufferinfo bi; int res; +#if defined(HAVE_PRI) int span = 0; +#endif /* defined(HAVE_PRI) */ int here = 0;/*!< TRUE if the channel interface already exists. */ int x; struct analog_pvt *analog_p = NULL; @@ -12303,7 +12305,9 @@ static struct dahdi_pvt *mkintf(int channel, const struct dahdi_chan_conf *conf, tmp->law_default = p.curlaw; tmp->law = p.curlaw; tmp->span = p.spanno; +#if defined(HAVE_PRI) span = p.spanno - 1; +#endif /* defined(HAVE_PRI) */ } else { chan_sig = 0; } @@ -13577,7 +13581,9 @@ static struct ast_channel *dahdi_request(const char *type, struct ast_format_cap struct dahdi_pvt *exitpvt; int channelmatched = 0; int groupmatched = 0; +#if defined(HAVE_PRI) || defined(HAVE_SS7) int transcapdigital = 0; +#endif /* defined(HAVE_PRI) || defined(HAVE_SS7) */ struct dahdi_starting_point start; ast_mutex_lock(&iflock); @@ -13633,8 +13639,10 @@ static struct ast_channel *dahdi_request(const char *type, struct ast_format_cap p->distinctivering = start.cadance; break; case 'd': +#if defined(HAVE_PRI) || defined(HAVE_SS7) /* If this is an ISDN call, make it digital */ transcapdigital = AST_TRANS_CAP_DIGITAL; +#endif /* defined(HAVE_PRI) || defined(HAVE_SS7) */ break; default: ast_log(LOG_WARNING, "Unknown option '%c' in '%s'\n", start.opt, (char *)data); |