mirror of
https://git.notmuchmail.org/git/notmuch
synced 2024-11-25 12:28:09 +01:00
Avoid complaints about empty address lists.
This commit is contained in:
parent
bae1ce09a3
commit
48d2e2dc44
1 changed files with 6 additions and 0 deletions
|
@ -204,6 +204,9 @@ gen_terms_address_names (Xapian::TermGenerator term_gen,
|
||||||
int i;
|
int i;
|
||||||
InternetAddress *address;
|
InternetAddress *address;
|
||||||
|
|
||||||
|
if (addresses == NULL)
|
||||||
|
return;
|
||||||
|
|
||||||
for (i = 0; i < internet_address_list_length (addresses); i++) {
|
for (i = 0; i < internet_address_list_length (addresses); i++) {
|
||||||
address = internet_address_list_get_address (addresses, i);
|
address = internet_address_list_get_address (addresses, i);
|
||||||
gen_terms_address_name (term_gen, address, address_type);
|
gen_terms_address_name (term_gen, address, address_type);
|
||||||
|
@ -234,6 +237,9 @@ add_terms_address_addrs (Xapian::Document doc,
|
||||||
int i;
|
int i;
|
||||||
InternetAddress *address;
|
InternetAddress *address;
|
||||||
|
|
||||||
|
if (addresses == NULL)
|
||||||
|
return;
|
||||||
|
|
||||||
for (i = 0; i < internet_address_list_length (addresses); i++) {
|
for (i = 0; i < internet_address_list_length (addresses); i++) {
|
||||||
address = internet_address_list_get_address (addresses, i);
|
address = internet_address_list_get_address (addresses, i);
|
||||||
add_term_address_addr (doc, address, address_type);
|
add_term_address_addr (doc, address, address_type);
|
||||||
|
|
Loading…
Reference in a new issue