[asterisk-commits] jpeeler: branch jpeeler/bug16709 r246124 - /team/jpeeler/bug16709/channels/
SVN commits to the Asterisk project
asterisk-commits at lists.digium.com
Wed Feb 10 12:16:34 CST 2010
Author: jpeeler
Date: Wed Feb 10 12:16:31 2010
New Revision: 246124
URL: http://svnview.digium.com/svn/asterisk?view=rev&rev=246124
Log:
back to square one
Modified:
team/jpeeler/bug16709/channels/chan_dahdi.c
Modified: team/jpeeler/bug16709/channels/chan_dahdi.c
URL: http://svnview.digium.com/svn/asterisk/team/jpeeler/bug16709/channels/chan_dahdi.c?view=diff&rev=246124&r1=246123&r2=246124
==============================================================================
--- team/jpeeler/bug16709/channels/chan_dahdi.c (original)
+++ team/jpeeler/bug16709/channels/chan_dahdi.c Wed Feb 10 12:16:31 2010
@@ -6877,11 +6877,6 @@
struct dahdi_spaninfo zi;
struct dahdi_params params;
- /* this is used only for unit testing purposes */
- if (p->fake_event) {
- return p->fake_event;
- }
-
memset(&zi, 0, sizeof(zi));
zi.spanno = p->span;
@@ -7007,7 +7002,7 @@
if(report_alarms & REPORT_SPAN_ALARMS && p->manages_span_alarms) {
if ((res = ioctl(p->subs[SUB_REAL].dfd, DAHDI_SPANSTAT, &di)) >= 0) {
- if (di.alarms != DAHDI_ALARM_NONE || p->fake_event) {
+ if (di.alarms != DAHDI_ALARM_NONE) {
ast_log(LOG_WARNING, "Detected alarm on span %d: %s\n", p->span, alarm_str);
manager_event(EVENT_FLAG_SYSTEM, "SpanAlarm",
"Alarm: %s\r\n"
@@ -14586,10 +14581,8 @@
} else {
ast_cli(a->fd, "Hookstate (FXS only): %s\n", ps.rxisoffhook ? "Offhook" : "Onhook");
}
-ast_log(LOG_WARNING, "jpeeler: about to set fake event\n");
-tmp->fake_event = DAHDI_ALARM_RED;
-handle_init_event(tmp, DAHDI_EVENT_ALARM);
/*
+//wish this worked, but it looks like DAHDI clears the alarm flags after copying everything else from userspace
ast_log(LOG_WARNING, "jpeeler: about to set params\n");
ps.chan_alarms = DAHDI_ALARM_RED;
if (ioctl(tmp->subs[SUB_REAL].dfd, DAHDI_SET_PARAMS, &ps) < 0) {
More information about the asterisk-commits
mailing list