From 63fc930c68d5e7456f160f10d06328ff15761cac Mon Sep 17 00:00:00 2001 From: Shaun Ruffell Date: Sun, 28 Sep 2008 17:29:12 +0000 Subject: 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 --- drivers/dahdi/wctdm.c | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) (limited to 'drivers/dahdi/wctdm.c') 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) { -- cgit v1.2.3