diff options
author | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2010-02-12 04:29:54 +0000 |
---|---|---|
committer | hiro <hiro@ee746299-78ed-0310-b773-934348b2243d> | 2010-02-12 04:29:54 +0000 |
commit | 2e693597aa60fb25b8a22b2c5c2fc0db86bad7c9 (patch) | |
tree | 23e02929ff2c0abb084ed0362992f7563154e79d /src | |
parent | e8570d3dfd2589b07746d6e84a11743a5a8cf09d (diff) |
optimized address auto-registration.
git-svn-id: svn://sylpheed.sraoss.jp/sylpheed/trunk@2467 ee746299-78ed-0310-b773-934348b2243d
Diffstat (limited to 'src')
-rw-r--r-- | src/compose.c | 19 |
1 files changed, 1 insertions, 18 deletions
diff --git a/src/compose.c b/src/compose.c index 36139969..15dca72f 100644 --- a/src/compose.c +++ b/src/compose.c @@ -3327,9 +3327,6 @@ static void compose_add_new_recipients_to_addressbook(Compose *compose) for (cur = to_list; cur != NULL; cur = cur->next) { gchar *orig_addr = cur->data; gchar *name, *addr; - gchar *compaddr; - gint count, i; - gboolean found = FALSE; name = procheader_get_fromname(orig_addr); addr = g_strdup(orig_addr); @@ -3339,21 +3336,7 @@ static void compose_add_new_recipients_to_addressbook(Compose *compose) name = NULL; } - count = complete_address(addr); - for (i = 1; i < count; i++) { - compaddr = get_complete_address(i); - if (compaddr) { - g_print("compaddr: %s\n", compaddr); - extract_address(compaddr); - if (!g_ascii_strcasecmp(addr, compaddr)) { - found = TRUE; - break; - } - } - } - clear_completion_cache(); - - if (found) + if (addressbook_has_address(addr)) debug_print("compose_add_new_recipients_to_addressbook: address <%s> already registered.\n", addr); else addressbook_add_contact_autoreg(name, addr, NULL); |