diff options
author | 2014-10-20 15:49:45 +0000 | |
---|---|---|
committer | 2014-10-20 15:49:45 +0000 | |
commit | 7c46d8a6f75a1304ddc3e4e6645e2d28da9ce989 (patch) | |
tree | 901d84c6cf1f2a6a04ecd6d76e51df70867d4762 /usr.bin/mandoc/mdoc.c | |
parent | correctly parse spacing around in-line equations (diff) | |
download | wireguard-openbsd-7c46d8a6f75a1304ddc3e4e6645e2d28da9ce989.tar.xz wireguard-openbsd-7c46d8a6f75a1304ddc3e4e6645e2d28da9ce989.zip |
correct the spacing after in-line equations
that start at the beginning of an input line
but end before the end of an input line
Diffstat (limited to 'usr.bin/mandoc/mdoc.c')
-rw-r--r-- | usr.bin/mandoc/mdoc.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.bin/mandoc/mdoc.c b/usr.bin/mandoc/mdoc.c index 7368dedca61..ee77219710c 100644 --- a/usr.bin/mandoc/mdoc.c +++ b/usr.bin/mandoc/mdoc.c @@ -1,4 +1,4 @@ -/* $OpenBSD: mdoc.c,v 1.116 2014/10/20 02:31:44 schwarze Exp $ */ +/* $OpenBSD: mdoc.c,v 1.117 2014/10/20 15:49:45 schwarze Exp $ */ /* * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv> * Copyright (c) 2010, 2012, 2013, 2014 Ingo Schwarze <schwarze@openbsd.org> @@ -236,7 +236,8 @@ int mdoc_parseln(struct mdoc *mdoc, int ln, char *buf, int offs) { - mdoc->flags |= MDOC_NEWLINE; + if (mdoc->last->type != MDOC_EQN || ln > mdoc->last->line) + mdoc->flags |= MDOC_NEWLINE; /* * Let the roff nS register switch SYNOPSIS mode early, |