summaryrefslogtreecommitdiff
path: root/drivers/dahdi/wctdm.c
diff options
context:
space:
mode:
authorShaun Ruffell <sruffell@digium.com>2008-09-28 17:29:12 +0000
committerShaun Ruffell <sruffell@digium.com>2008-09-28 17:29:12 +0000
commit14bc121eb2db53ef28cee245e8e625022b4405d0 (patch)
treeddf487c2bc3b7ce240c857ee1041feb12fe6c361 /drivers/dahdi/wctdm.c
parent158a56746f6d4bbcdfe224b363f7788903a59b64 (diff)
Improve reliablity of UK caller ID for the TDM400P by not allowing the
ringdebounce to be decremented when it is at 0 already. Related to issue #12531. Reported mattbrown, fix suggested by benbrown. git-svn-id: http://svn.asterisk.org/svn/dahdi/linux/trunk@5007 a0bf4364-ded3-4de4-8d8a-66a801d63aff
Diffstat (limited to 'drivers/dahdi/wctdm.c')
-rw-r--r--drivers/dahdi/wctdm.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/drivers/dahdi/wctdm.c b/drivers/dahdi/wctdm.c
index 5d4b05c..1c1ea44 100644
--- a/drivers/dahdi/wctdm.c
+++ b/drivers/dahdi/wctdm.c
@@ -771,7 +771,8 @@ static inline void wctdm_voicedaa_check_hook(struct wctdm *wc, int card)
if (!fxo->offhook) {
if (fwringdetect) {
res = wc->reg0shadow[card] & 0x60;
- if (fxo->ringdebounce--) {
+ if (fxo->ringdebounce) {
+ --fxo->ringdebounce;
if (res && (res != fxo->lastrdtx) &&
(fxo->battery == BATTERY_PRESENT)) {
if (!fxo->wasringing) {