Sorry, missed the list.. -------- Original Message -------- Date: Wed, 27 Mar 2013 18:14:18 +0100 From: Steffen "Daode" Nurpmeso <[email protected]> To: [email protected] Subject: Re: Testing s-nail 14.2
Hello, [email protected] wrote: |Hi, | |I am currently testing version 14.2 of s-nail. First thing I noticed: |If "bsdcompat" is set, the header summary looks garbled: It prints |a newline before the closing quote of the subject. I just pushed the appended fix to the *master* branch. Many thanks for reporting this issue! |Regards |Peters Ciao, and i hope the second look is more appealing.. --steffen Date: 2013-03-27 18:04:11 +0100 cmd1.c:hprf(): fix subject length calculation.. (printhead(): support "-" for all fields etc., 2013-03-09) added support for field alignment for (almost) all fields. It was missed that subtracting a value from a negative value actually increases the result. Thanks to (peters AT schwertfisch DOT de) for pointing this out! diff --git a/cmd1.c b/cmd1.c index 4000afa..a37b28e 100644 --- a/cmd1.c +++ b/cmd1.c @@ -582,9 +582,8 @@ jputc: fromlen = ABS(n); if (isto) /* XXX tr()! */ fromlen -= 3; - fprintf(f, "%s%s", isto ? "To " : "", + subjlen -= fprintf(f, "%s%s", isto ? "To " : "", colalign(name, fromlen, n)); - subjlen -= ABS(n); break; case 'd': if (datefmt != NULL) { @@ -613,6 +612,7 @@ jputc: subjlen -= fprintf(f, "%*ld", n, mp->m_xlines); else { + n = ABS(n); subjlen -= n; while (n--) putc(' ', f); @@ -633,11 +633,12 @@ jputc: B = 1; /*FALLTHRU*/ case 's': - n = (n != 0) ? n : subjlen - 2; + if (n == 0) + n = subjlen - 2; if (n > 0 && s < 0) n = -n; if (B) - n -= 2; + n -= (n < 0) ? -2 : 2; if (subjline != NULL && n != 0) { /* pretty pathetic */ fprintf(f, B ? "\"%s\"" : "%s", @@ -667,9 +668,8 @@ jputc: for (i=msgCount; i>999; i/=10) n++; } - fprintf(f, "%*ld", n, threaded ? + subjlen -= fprintf(f, "%*ld", n, threaded ? mp->m_threadpos : mesg); - subjlen -= n; break; case 'c': #ifdef USE_SCORE ------------------------------------------------------------------------------ Own the Future-Intel® Level Up Game Demo Contest 2013 Rise to greatness in Intel's independent game demo contest. Compete for recognition, cash, and the chance to get your game on Steam. $5K grand prize plus 10 genre and skill prizes. Submit your demo by 6/6/13. http://p.sf.net/sfu/intel_levelupd2d _______________________________________________ nail-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/nail-devel
