[Users] [Bug 2835] New: add_address() in addr_compl.c should allow a NULL name
noreply at thewildbeast.co.uk
noreply at thewildbeast.co.uk
Sun Dec 9 04:03:02 CET 2012
http://www.thewildbeast.co.uk/claws-mail/bugzilla/show_bug.cgi?id=2835
Summary: add_address() in addr_compl.c should allow a NULL name
Product: Claws Mail
Version: CVS
Platform: PC
OS/Version: Linux
Status: NEW
Severity: minor
Priority: P3
Component: Other
AssignedTo: users at lists.claws-mail.org
ReportedBy: neels at hofmeyr.de
Created an attachment (id=1204)
--> (http://www.thewildbeast.co.uk/claws-mail/bugzilla/attachment.cgi?id=1204)
This patch, along with a change that adds an address book refresh to the
address keeper plugin, allows the plugin to immediately update address
completion with new addresses.
For a caller of addrbook_add_contact() (like the address-keeper plugin), it is
impossible to enter a new address with an empty name, so that it shows up in
the address completion, without doing a complete addressbook reload (claws-mail
restart).
addrbook_add_contact() via addritem_person_set_common_name() and
mgu_replace_string() strips the name to NULL. However, a NULL name invariably
triggers a condition in addr_compl.c:add_address(), causing the address to be
dropped from the address completion cache:
- if (!name || !address) {
- if (address || nick || alias || !grp_emails)
- return -1;
I don't really understand the condition, especially when comparing it to what
it was in 3.8.0.
A patch will follow which collapses the condition to something that seems to
make sense, and which sets a NULL name to the empty string, as is expected in
that code path.
This patch, along with a change that adds an address book refresh to the
address keeper plugin, allows the plugin to immediately update address
completion with new addresses.
--
Configure bugmail: http://www.thewildbeast.co.uk/claws-mail/bugzilla/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the assignee for the bug.
More information about the Users
mailing list