mblaze

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

commit ab75d14d62a5d57b104ae8f77a489a74025c797f
parent f86bb4d88ff1b7e1dd10eb51ac155948106902d5
Author: Duncaen <mail@duncano.de>
Date:   Fri, 22 Jul 2016 21:34:54 +0200

mpick: fix new detection

Diffstat:
mpick.c | 6+++---
1 file changed, 3 insertions(+), 3 deletions(-)

diff --git a/mpick.c b/mpick.c @@ -790,11 +790,11 @@ oneline(char *line, long idx) *e-- = 0; m.msg = blaze822(m.fpath); - if (!m.msg) { + if (!m.msg) return; - } - if (strstr(m.fpath, "/new/") != NULL) + if ((e = strrchr(m->fpath, '/') - 1) && (e - m->fpath) >= 2 && + *e-- == 'w' && *e-- == 'e' && *e-- == 'n') m.flags |= FLAG_NEW; if (cur && strcmp(cur, m.fpath) == 0)