From 072b9211c04d4a04bdcbdc29fe93a9e582c2aa80 Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Fri, 12 Oct 2007 23:49:43 +0000 Subject: [PATCH] make compares case insensitive git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@5862 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- src/mod/applications/mod_enum/mod_enum.c | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/src/mod/applications/mod_enum/mod_enum.c b/src/mod/applications/mod_enum/mod_enum.c index d9d89217e8..e74453677e 100644 --- a/src/mod/applications/mod_enum/mod_enum.c +++ b/src/mod/applications/mod_enum/mod_enum.c @@ -223,17 +223,17 @@ static void add_result(enum_query_t * q, int order, int preference, char *servic rp = q->results; - while (rp && strcmp(rp->service, new_result->service)) { + while (rp && strcasecmp(rp->service, new_result->service)) { prev = rp; rp = rp->next; } - while (rp && !strcmp(rp->service, new_result->service) && new_result->order > rp->order) { + while (rp && !strcasecmp(rp->service, new_result->service) && new_result->order > rp->order) { prev = rp; rp = rp->next; } - while (rp && !strcmp(rp->service, new_result->service) && new_result->preference > rp->preference) { + while (rp && !strcasecmp(rp->service, new_result->service) && new_result->preference > rp->preference) { prev = rp; rp = rp->next; } @@ -541,7 +541,7 @@ SWITCH_STANDARD_DIALPLAN(enum_dialplan_hunt) for (rtp = globals.route_order; rtp; rtp = rtp->next) { for (rp = results; rp; rp = rp->next) { - if (!strcmp(rtp->service, rp->service)) { + if (!strcasecmp(rtp->service, rp->service)) { switch_caller_extension_add_application(session, extension, "bridge", rp->route); } } @@ -596,7 +596,7 @@ SWITCH_STANDARD_APP(enum_app_function) for (rtp = globals.route_order; rtp; rtp = rtp->next) { for (rp = results; rp; rp = rp->next) { - if (!strcmp(rtp->service, rp->service)) { + if (!strcasecmp(rtp->service, rp->service)) { snprintf(vbuf, sizeof(vbuf), "enum_route_%d", cnt++); switch_channel_set_variable(channel, vbuf, rp->route); @@ -661,7 +661,7 @@ SWITCH_STANDARD_API(enum_function) for (rtp = globals.route_order; rtp; rtp = rtp->next) { for (rp = results; rp; rp = rp->next) { - if (!strcmp(rtp->service, rp->service)) { + if (!strcasecmp(rtp->service, rp->service)) { stream->write_function(stream, "%d\t%d\t%-10s\t%s\n", rp->order, rp->preference, rp->service, rp->route); } }