From 9ca12b83de76e7b30b71e8b8c504deb21d8a09fd Mon Sep 17 00:00:00 2001 From: Dennis Schafroth Date: Mon, 21 May 2012 14:48:36 +0000 Subject: [PATCH] Remove hard-coded right trim. Use icuchain instead --- src/termlists.c | 7 +------ 1 file changed, 1 insertion(+), 6 deletions(-) diff --git a/src/termlists.c b/src/termlists.c index ea93130..54e5f67 100644 --- a/src/termlists.c +++ b/src/termlists.c @@ -112,16 +112,11 @@ void termlist_insert(struct termlist *tl, const char *display_term, { unsigned int bucket; struct termlist_bucket **p; - char buf[256], *cp; + char buf[256]; if (strlen(norm_term) > 255) return; strcpy(buf, norm_term); - /* chop right */ - /* - for (cp = buf + strlen(buf); cp != buf && strchr(",. -", cp[-1]); cp--) - cp[-1] = '\0'; - */ bucket = jenkins_hash((unsigned char *)buf) % tl->hash_size; for (p = &tl->hashtable[bucket]; *p; p = &(*p)->next) { -- 1.7.10.4