From mboxrd@z Thu Jan 1 00:00:00 1970 Received: from scc-mailout.scc.kit.edu (scc-mailout.scc.kit.edu [129.13.185.201]) by krisdoz.my.domain (8.14.3/8.14.3) with ESMTP id p35LmcYt003310 for ; Tue, 5 Apr 2011 17:48:40 -0400 (EDT) Received: from hekate.usta.de (asta-nat.asta.uni-karlsruhe.de [172.22.63.82]) by scc-mailout-01.scc.kit.edu with esmtp (Exim 4.72 #1) id 1Q7E72-0005za-Va; Tue, 05 Apr 2011 23:48:36 +0200 Received: from donnerwolke.usta.de ([172.24.96.3]) by hekate.usta.de with esmtp (Exim 4.72) (envelope-from ) id 1Q7E72-0006KV-W5; Tue, 05 Apr 2011 23:48:37 +0200 Received: from iris.usta.de ([172.24.96.5] helo=usta.de) by donnerwolke.usta.de with esmtp (Exim 4.69) (envelope-from ) id 1Q7E72-0004oV-V0; Tue, 05 Apr 2011 23:48:36 +0200 Received: from schwarze by usta.de with local (Exim 4.72) (envelope-from ) id 1Q7E72-0004pB-JU; Tue, 05 Apr 2011 23:48:36 +0200 Date: Tue, 5 Apr 2011 23:48:36 +0200 From: Ingo Schwarze To: Tristan Le Guern , tech@mdocml.bsd.lv Cc: espie@nerim.net Subject: PATCH: .de macro name may end in tab Message-ID: <20110405214836.GD30791@iris.usta.de> References: X-Mailinglist: mdocml-tech Reply-To: tech@mdocml.bsd.lv MIME-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline In-Reply-To: User-Agent: Mutt/1.5.21 (2010-09-15) Hi Tristan, Tristan Le Guern wrote on Tue, Apr 05, 2011 at 05:25:22PM +0200: > i notice some indentation errors in fvwm man page in > 'THE VIRTUAL DESKTOP' section. That's a bug in mandoc(1), thanks for reporting! The page has this: .deEX\"Begin example Searching for a space, mandoc misses the end of the EX macro name and ends up defining a macro with a wrong name. Here is a fix; OK? Yours, Ingo Index: roff.c =================================================================== RCS file: /cvs/src/usr.bin/mandoc/roff.c,v retrieving revision 1.32 diff -u -p -r1.32 roff.c --- roff.c 20 Mar 2011 23:36:42 -0000 1.32 +++ roff.c 5 Apr 2011 21:33:48 -0000 @@ -745,10 +745,10 @@ roff_block(ROFF_ARGS) (*r->msg)(MANDOCERR_REQUEST, r->data, ln, ppos, roffs[tok].name); - while ((*bufp)[pos] && ' ' != (*bufp)[pos]) + while ((*bufp)[pos] && !isspace((*bufp)[pos])) pos++; - while (' ' == (*bufp)[pos]) + while (isspace((*bufp)[pos])) (*bufp)[pos++] = '\0'; } @@ -769,9 +769,7 @@ roff_block(ROFF_ARGS) /* If present, process the custom end-of-line marker. */ sv = pos; - while ((*bufp)[pos] && - ' ' != (*bufp)[pos] && - '\t' != (*bufp)[pos]) + while ((*bufp)[pos] && !isspace((*bufp)[pos])) pos++; /* -- To unsubscribe send an email to tech+unsubscribe@mdocml.bsd.lv