From 4ff84e46a5b03bf0ba8b61fadf7c22c4cd82cd5c Mon Sep 17 00:00:00 2001 From: Anthony Minessale Date: Tue, 23 Oct 2007 02:59:46 +0000 Subject: [PATCH] fix return val in switch_stristr git-svn-id: http://svn.freeswitch.org/svn/freeswitch/trunk@6024 d0543943-73ff-0310-b7d9-9358b9ac24b2 --- src/switch_utils.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/src/switch_utils.c b/src/switch_utils.c index 61f712b7c9..8a27a71cc8 100644 --- a/src/switch_utils.c +++ b/src/switch_utils.c @@ -205,7 +205,7 @@ SWITCH_DECLARE(const char *) switch_stristr(const char *str, const char *instr) while(*a && *b) { if (tolower(*b) == tolower(*a)) { if (++x == score) { - return p; + return b - x + 1; } a++; } else {