stringlist_to_clist() will now not try to encode empty stringlists
authorKrista Bennett <krista@pep-project.org>
Tue, 24 Oct 2017 12:08:45 +0200
changeset 2197dabca211d42b
parent 2193 0dc7346c26fc
child 2198 481a5da58188
stringlist_to_clist() will now not try to encode empty stringlists
src/mime.c
     1.1 --- a/src/mime.c	Tue Oct 24 11:26:38 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;