diff options
author | Ingo Schwarze <schwarze@openbsd.org> | 2016-08-28 16:15:12 +0000 |
---|---|---|
committer | Ingo Schwarze <schwarze@openbsd.org> | 2016-08-28 16:15:12 +0000 |
commit | 7b96be561b6468986e08aedac7c8aab7198f722c (patch) | |
tree | 74eaebbf1ec39ab846e5e44f3a6ccd418c304ebb | |
parent | 41f393601155f987e273b2a177289e9b3deaecea (diff) | |
download | mandoc-7b96be561b6468986e08aedac7c8aab7198f722c.tar.gz |
If a line inside .Bl -column starts with a tab character
and there was no preceding .It macro, do not read the byte
before the beginning of the line buffer.
Found by tb@ with afl@.
-rw-r--r-- | mdoc_argv.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/mdoc_argv.c b/mdoc_argv.c index 8366be39..258ada12 100644 --- a/mdoc_argv.c +++ b/mdoc_argv.c @@ -480,7 +480,7 @@ args(struct roff_man *mdoc, int line, int *pos, * unless there is a blank in between. */ - if (p[-1] != ' ') + if (p > buf && p[-1] != ' ') mdoc->flags |= MDOC_PHRASEQL; if (p[1] != ' ') mdoc->flags |= MDOC_PHRASEQN; |