aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/mandoc.c
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2010-08-24 12:18:48 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2010-08-24 12:18:48 +0000
commit3734245a5a164c1ba48ac02cb3131143431b996b (patch)
tree6586c23c6f21da438aab9837f48deacc6e640c55 /mandoc.c
parent8f9f46b6458dea1bcb7ba265c47247d2858f6351 (diff)
downloadmandoc-3734245a5a164c1ba48ac02cb3131143431b996b.tar.gz
mandoc-3734245a5a164c1ba48ac02cb3131143431b996b.tar.zst
mandoc-3734245a5a164c1ba48ac02cb3131143431b996b.zip
Strip out the `\z' escape. This is the first recursive sequence,
getting mandoc ready to handle pod2man's complex escapes.
Diffstat (limited to 'mandoc.c')
-rw-r--r--mandoc.c9
1 files changed, 8 insertions, 1 deletions
diff --git a/mandoc.c b/mandoc.c
index 53e7c7b6..5505c5f3 100644
--- a/mandoc.c
+++ b/mandoc.c
@@ -1,4 +1,4 @@
-/* $Id: mandoc.c,v 1.29 2010/08/20 01:02:07 schwarze Exp $ */
+/* $Id: mandoc.c,v 1.30 2010/08/24 12:18:48 kristaps Exp $ */
/*
* Copyright (c) 2008, 2009, 2010 Kristaps Dzonsons <kristaps@bsd.lv>
*
@@ -171,6 +171,13 @@ mandoc_special(char *p)
case ('['):
term = ']';
break;
+ case ('z'):
+ len = 1;
+ if ('\\' == *p) {
+ p += mandoc_special(p);
+ return(*p ? (int)(p - sv) : 0);
+ }
+ break;
default:
len = 1;
p--;