[evolution-data-server] Bug #485283 - Filter is not working for mix letter case



commit 400596f76180e9b641889d93121b8855d020cce8
Author: Milan Crha <mcrha redhat com>
Date:   Tue Feb 7 13:46:09 2012 +0100

    Bug #485283 - Filter is not working for mix letter case

 camel/camel-search-private.c |   23 -----------------------
 1 files changed, 0 insertions(+), 23 deletions(-)
---
diff --git a/camel/camel-search-private.c b/camel/camel-search-private.c
index 680343b..d196326 100644
--- a/camel/camel-search-private.c
+++ b/camel/camel-search-private.c
@@ -338,9 +338,7 @@ header_match (const gchar *value,
               const gchar *match,
               camel_search_match_t how)
 {
-	const guchar *p;
 	gint vlen, mlen;
-	gunichar c;
 
 	if (how == CAMEL_SEARCH_MATCH_SOUNDEX)
 		return header_soundex (value, match);
@@ -350,27 +348,6 @@ header_match (const gchar *value,
 	if (vlen < mlen)
 		return FALSE;
 
-	/* from dan the man, if we have mixed case, perform a case-sensitive match,
-	 * otherwise not */
-	p = (const guchar *) match;
-	while ((c = camel_utf8_getc (&p))) {
-		if (g_unichar_isupper (c)) {
-			switch (how) {
-			case CAMEL_SEARCH_MATCH_EXACT:
-				return strcmp (value, match) == 0;
-			case CAMEL_SEARCH_MATCH_CONTAINS:
-				return strstr (value, match) != NULL;
-			case CAMEL_SEARCH_MATCH_STARTS:
-				return strncmp (value, match, mlen) == 0;
-			case CAMEL_SEARCH_MATCH_ENDS:
-				return strcmp (value + vlen - mlen, match) == 0;
-			default:
-				break;
-			}
-			return FALSE;
-		}
-	}
-
 	switch (how) {
 	case CAMEL_SEARCH_MATCH_EXACT:
 		return camel_ustrcasecmp (value, match) == 0;



[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]