mblaze

Unix utilities to deal with Maildir - my mirror
git clone https://pi.duncano.de/git/mblaze.git
Log | Files | Refs | README | COPYING

commit 6948b408a292db316e86d777e574891ff5cedbfa
parent d65041c3866ecd00c61839591009fb105078145d
Author: Leah Neukirchen <leah@vuxu.org>
Date:   Mon, 21 Aug 2017 19:12:19 +0200

mflow: use blaze822_mime_parameter properly

Found using spam corpus at http://untroubled.org/spam/2017-08.7z.

Diffstat:
mflow.c | 8++++----
1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/mflow.c b/mflow.c @@ -105,10 +105,10 @@ main() char *ct = getenv("PIPE_CONTENTTYPE"); if (ct) { char *s, *se; - blaze822_mime_parameter(ct, "format", &s, &se); - reflow = s && (strncasecmp(s, "flowed", 6) == 0); - blaze822_mime_parameter(ct, "delsp", &s, &se); - delsp = s && (strncasecmp(s, "yes", 3) == 0); + if (blaze822_mime_parameter(ct, "format", &s, &se) && s) + reflow = (strncasecmp(s, "flowed", 6) == 0); + if (blaze822_mime_parameter(ct, "delsp", &s, &se) && s) + delsp = (strncasecmp(s, "yes", 3) == 0); } char *cols = getenv("COLUMNS");