diff -uNr asterisk-1.6.2.0.ORIG/channels/chan_dahdi.c asterisk-1.6.2.0/channels/chan_dahdi.c --- asterisk-1.6.2.0.ORIG/channels/chan_dahdi.c 2010-01-04 13:57:12.000000000 +0000 +++ asterisk-1.6.2.0/channels/chan_dahdi.c 2010-01-04 14:08:54.000000000 +0000 @@ -8419,6 +8419,7 @@ } if (i & DAHDI_IOMUX_SIGEVENT) { res = dahdi_get_event(p->subs[idx].dfd); + if (res == DAHDI_EVENT_NOALARM) p->inalarm = 0; ast_log(LOG_NOTICE, "Got event %d (%s)...\n", res, event2str(res)); if (p->cid_signalling == CID_SIG_V23_JP) { @@ -8521,6 +8522,7 @@ if (i & DAHDI_IOMUX_SIGEVENT) { res = dahdi_get_event(p->subs[idx].dfd); ast_log(LOG_NOTICE, "Got event %d (%s)...\n", res, event2str(res)); + if (res == DAHDI_EVENT_NOALARM) p->inalarm = 0; res = 0; /* Let us detect distinctive ring */ @@ -8670,6 +8672,7 @@ if (i & DAHDI_IOMUX_SIGEVENT) { res = dahdi_get_event(p->subs[idx].dfd); ast_log(LOG_NOTICE, "Got event %d (%s)...\n", res, event2str(res)); + if (res == DAHDI_EVENT_NOALARM) p->inalarm = 0; /* If we get a PR event, they hung up while processing calerid */ if ( res == DAHDI_EVENT_POLARITY && p->hanguponpolarityswitch && p->polarity == POLARITY_REV) { ast_log(LOG_DEBUG, "Hanging up due to polarity reversal on channel %d while detecting callerid\n", p->channel); @@ -8739,6 +8742,7 @@ if (i & DAHDI_IOMUX_SIGEVENT) { res = dahdi_get_event(p->subs[idx].dfd); ast_log(LOG_NOTICE, "Got event %d (%s)...\n", res, event2str(res)); + if (res == DAHDI_EVENT_NOALARM) p->inalarm = 0; res = 0; /* Let us detect callerid when the telco uses distinctive ring */