From 91cb42b7eaa91d29c170720255a277296ffd8752 Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Fri, 8 Jun 2007 15:17:43 +0000 Subject: [PATCH] fix accidental missing event enum name git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5291 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- .../mod_event_socket/mod_event_socket.c | 13 +++++++++---- src/switch_event.c | 1 + 2 files changed, 10 insertions(+), 4 deletions(-) diff --git a/src/mod/event_handlers/mod_event_socket/mod_event_socket.c b/src/mod/event_handlers/mod_event_socket/mod_event_socket.c index 327eff0bda..fdeae10aa3 100644 --- a/src/mod/event_handlers/mod_event_socket/mod_event_socket.c +++ b/src/mod/event_handlers/mod_event_socket/mod_event_socket.c @@ -129,19 +129,24 @@ static void event_handler(switch_event_t *event) if (!switch_test_flag(l, LFLAG_EVENTS)) { continue; } - - if (l->event_list[(uint8_t) SWITCH_EVENT_ALL]) { + + if (l->event_list[SWITCH_EVENT_ALL]) { send = 1; - } else if ((l->event_list[(uint8_t) event->event_id])) { + } else if ((l->event_list[event->event_id])) { if (event->event_id != SWITCH_EVENT_CUSTOM || (event->subclass && switch_core_hash_find(l->event_hash, event->subclass->name))) { send = 1; } + } else { + int x; + for(x = 0; x <= SWITCH_EVENT_ALL; x++) { + printf("%d ", l->event_list[x]); + } } if (send && switch_test_flag(l, LFLAG_MYEVENTS)) { char *uuid = switch_event_get_header(event, "unique-id"); if (!uuid || strcmp(uuid, switch_core_session_get_uuid(l->session))) { - send = 1; + send = 0; } } diff --git a/src/switch_event.c b/src/switch_event.c index 27bfe0c799..7a408108f8 100644 --- a/src/switch_event.c +++ b/src/switch_event.c @@ -133,6 +133,7 @@ static char *EVENT_NAMES[] = { "CODEC", "BACKGROUND_JOB", "DETECTED_SPEECH", + "DETECTED_FAX", "PRIVATE_COMMAND", "HEARTBEAT", "TRAP",