mblaze

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

commit 2aaa3cecd8a21c975c5bea886c678775627e90e7
parent 0f9d98a4f4ef328ce31915fd56092b4f3cc185a9
Author: Christian Neukirchen <chneukirchen@gmail.com>
Date:   Mon,  1 Aug 2016 00:04:35 +0200

blaze822: blaze822_chdr: downcase header

Diffstat:
blaze822.c | 4++++
mshow.c | 2+-
2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/blaze822.c b/blaze822.c @@ -436,7 +436,11 @@ char * blaze822_chdr(struct message *mesg, const char *chdr) { char hdr[256]; + char *c; + size_t l = snprintf(hdr, sizeof hdr, "%c%s:", 0, chdr); + for (c = hdr+1; *c; c++) + *c = lc(*c); return blaze822_hdr_(mesg, hdr, l); } diff --git a/mshow.c b/mshow.c @@ -683,7 +683,7 @@ show(char *file) *n = 0; v = blaze822_chdr(msg, h); if (v) { - if (strcmp("date", h) == 0) + if (strcasecmp("date", h) == 0) print_date_header(v); else print_decode_header(h, v);