summaryrefslogtreecommitdiffstats
path: root/usr.bin/mandoc/mdoc.c
diff options
context:
space:
mode:
authorschwarze <schwarze@openbsd.org>2010-12-26 21:04:19 +0000
committerschwarze <schwarze@openbsd.org>2010-12-26 21:04:19 +0000
commit6f2077997f033286f7b344cfd08e37cf622804f1 (patch)
treedab4acdaf3ebf6ae1dbc330d416522b706017384 /usr.bin/mandoc/mdoc.c
parentKill pmap_phys_address(), and force every driver's mmap() routine to return (diff)
downloadwireguard-openbsd-6f2077997f033286f7b344cfd08e37cf622804f1.tar.xz
wireguard-openbsd-6f2077997f033286f7b344cfd08e37cf622804f1.zip
Behave more like groff (both old and new): Specifying both .%T and .%J in
an .Rs block causes the title to be quoted instead of underlined, such that journal title and article title appear visually different. Original diff from kristaps@, simplified by me, tweaked again by kristaps@.
Diffstat (limited to 'usr.bin/mandoc/mdoc.c')
-rw-r--r--usr.bin/mandoc/mdoc.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/usr.bin/mandoc/mdoc.c b/usr.bin/mandoc/mdoc.c
index f904ea1297b..1fc7a423202 100644
--- a/usr.bin/mandoc/mdoc.c
+++ b/usr.bin/mandoc/mdoc.c
@@ -1,4 +1,4 @@
-/* $Id: mdoc.c,v 1.73 2010/12/21 23:57:31 schwarze Exp $ */
+/* $Id: mdoc.c,v 1.74 2010/12/26 21:04:19 schwarze Exp $ */
/*
* Copyright (c) 2008, 2009, 2010 Kristaps Dzonsons <kristaps@bsd.lv>
* Copyright (c) 2010 Ingo Schwarze <schwarze@openbsd.org>
@@ -541,6 +541,9 @@ mdoc_node_free(struct mdoc_node *p)
if (MDOC_An == p->tok)
if (p->data.An)
free(p->data.An);
+ if (MDOC_Rs == p->tok && MDOC_BLOCK == p->type)
+ if (p->data.Rs)
+ free(p->data.Rs);
if (MDOC_TS == p->tok && MDOC_BLOCK == p->type)
if (p->data.TS)
tbl_free(p->data.TS);