stringlist_to_clist() will now not try to encode empty stringlists test_diphoton
authorKrista Bennett <krista@pep-project.org>
Tue, 24 Oct 2017 12:08:45 +0200
branchtest_diphoton
changeset 2196e680ca5b914b
parent 2194 27024582896d
child 2199 6a4251cbe3b2
stringlist_to_clist() will now not try to encode empty stringlists
src/mime.c
     1.1 --- a/src/mime.c	Tue Oct 24 11:38:39 2017 +0200
     1.2 +++ b/src/mime.c	Tue Oct 24 12:08:45 2017 +0200
     1.3 @@ -391,6 +391,9 @@
     1.4      if (cl == NULL)
     1.5          return NULL;
     1.6  
     1.7 +    if (!sl || ((!sl->value || sl->value[0] == '\0') && sl->next == NULL))
     1.8 +        return cl;
     1.9 +        
    1.10      stringlist_t *_sl;
    1.11      for (_sl = sl; _sl; _sl = _sl->next) {
    1.12          int r;