]> granicus.if.org Git - neomutt/commitdiff
Add a test for NULL parameter attribute too
authorKevin McCarthy <kevin@8t8.us>
Mon, 6 May 2019 19:37:04 +0000 (12:37 -0700)
committerRichard Russon <rich@flatcap.org>
Fri, 10 May 2019 14:16:40 +0000 (15:16 +0100)
Just to be sure we don't have any issues with the new continuation
code.  The mutt_set_parameter() code doesn't actively prevent a null
attribute.

Co-authored-by: Richard Russon <rich@flatcap.org>
sendlib.c

index 549991f3276ded7394e0f157378f4ee54863d8fc..ac2dc7555850b1f8b18e84f7e85a0569304302ef 100644 (file)
--- a/sendlib.c
+++ b/sendlib.c
@@ -369,7 +369,7 @@ int mutt_write_mime_header(struct Body *a, FILE *fp)
     struct Parameter *np = NULL;
     TAILQ_FOREACH(np, &a->parameter, entries)
     {
-      if (!np->value)
+      if (!np->attribute || !np->value)
         continue;
 
       struct ParameterList param_conts = rfc2231_encode_string(np->attribute, np->value);