summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorschwarze <schwarze@openbsd.org>2017-03-08 17:51:29 +0000
committerschwarze <schwarze@openbsd.org>2017-03-08 17:51:29 +0000
commitec6791d72805854a9543721d9a0f97a0c2d58e03 (patch)
tree6331459dcededca0e10b40e38e8947ca171e27ac
parentDo not increment .Bl -enum list markers beyond two digits. (diff)
downloadwireguard-openbsd-ec6791d72805854a9543721d9a0f97a0c2d58e03.tar.xz
wireguard-openbsd-ec6791d72805854a9543721d9a0f97a0c2d58e03.zip
The CommonMark specification allows list markers fo the form "number) "
as well as "number. ", so escape closing parentheses after leading digits to improve portability.
-rw-r--r--usr.bin/mandoc/mdoc_markdown.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/mandoc/mdoc_markdown.c b/usr.bin/mandoc/mdoc_markdown.c
index 4951be2de3b..3b4774542f2 100644
--- a/usr.bin/mandoc/mdoc_markdown.c
+++ b/usr.bin/mandoc/mdoc_markdown.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: mdoc_markdown.c,v 1.11 2017/03/08 17:40:17 schwarze Exp $ */
+/* $OpenBSD: mdoc_markdown.c,v 1.12 2017/03/08 17:51:29 schwarze Exp $ */
/*
* Copyright (c) 2017 Ingo Schwarze <schwarze@openbsd.org>
*
@@ -535,7 +535,7 @@ md_word(const char *s)
bs = escflags & ESC_HYP && !code_blocks;
break;
case ')':
- bs = escflags & ESC_PAR && !code_blocks;
+ bs = escflags & (ESC_NUM | ESC_PAR) && !code_blocks;
break;
case '*':
case '[':