diff options
author | Ingo Schwarze <schwarze@cvs.openbsd.org> | 2015-06-27 13:25:31 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@cvs.openbsd.org> | 2015-06-27 13:25:31 +0000 |
commit | 077a1eb1eb781836e597cdb21a412504402045af (patch) | |
tree | d61177fe1fc31f55168d9e4ea64b2175e4b7efed /usr.bin | |
parent | f82f3b63e24b04d6f086c68f96343983c4ee1b73 (diff) |
Ignore blank characters at the beginning of a conditional block,
that is, after "\{".
Issue found by Markus <Waldeck at gmx dot de> in bash(1).
Diffstat (limited to 'usr.bin')
-rw-r--r-- | usr.bin/mandoc/roff.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/usr.bin/mandoc/roff.c b/usr.bin/mandoc/roff.c index 62f524f3976..1005fff77a9 100644 --- a/usr.bin/mandoc/roff.c +++ b/usr.bin/mandoc/roff.c @@ -1,4 +1,4 @@ -/* $OpenBSD: roff.c,v 1.143 2015/05/31 23:12:16 schwarze Exp $ */ +/* $OpenBSD: roff.c,v 1.144 2015/06/27 13:25:30 schwarze Exp $ */ /* * Copyright (c) 2008-2012, 2014 Kristaps Dzonsons <kristaps@bsd.lv> * Copyright (c) 2010-2015 Ingo Schwarze <schwarze@openbsd.org> @@ -2263,6 +2263,8 @@ roff_cond(ROFF_ARGS) if (buf->buf[pos] == '\\' && buf->buf[pos + 1] == '{') { r->last->endspan = -1; pos += 2; + while (buf->buf[pos] == ' ') + pos++; goto out; } |