summaryrefslogtreecommitdiffstatshomepage
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2010-07-22 14:03:50 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2010-07-22 14:03:50 +0000
commit78a0de5a604ee23de16896cd3b2f2f1b70fc1dca (patch)
treedd29e23f890e6f1e67bfa719f0aee69c0674d76e
parent6517639ca42037e224f73f48f9fe1c1bfab97b6a (diff)
downloadmandoc-78a0de5a604ee23de16896cd3b2f2f1b70fc1dca.tar.gz
mandoc-78a0de5a604ee23de16896cd3b2f2f1b70fc1dca.tar.zst
mandoc-78a0de5a604ee23de16896cd3b2f2f1b70fc1dca.zip
Accept "\s0" (i.e., properly ignore it). Found in the wild (e.g., gfdl.7).
-rw-r--r--mandoc.c5
-rw-r--r--out.c5
2 files changed, 8 insertions, 2 deletions
diff --git a/mandoc.c b/mandoc.c
index 69972c04..68caf719 100644
--- a/mandoc.c
+++ b/mandoc.c
@@ -1,4 +1,4 @@
-/* $Id: mandoc.c,v 1.25 2010/07/21 20:35:03 kristaps Exp $ */
+/* $Id: mandoc.c,v 1.26 2010/07/22 14:03:50 kristaps Exp $ */
/*
* Copyright (c) 2008, 2009, 2010 Kristaps Dzonsons <kristaps@bsd.lv>
*
@@ -109,6 +109,9 @@ mandoc_special(char *p)
case ('\''):
term = '\'';
break;
+ case ('0'):
+ i++;
+ /* FALLTHROUGH */
default:
len = 1;
p--;
diff --git a/out.c b/out.c
index 62fda5cf..d501aecc 100644
--- a/out.c
+++ b/out.c
@@ -1,4 +1,4 @@
-/* $Id: out.c,v 1.21 2010/07/21 20:35:03 kristaps Exp $ */
+/* $Id: out.c,v 1.22 2010/07/22 14:03:50 kristaps Exp $ */
/*
* Copyright (c) 2009, 2010 Kristaps Dzonsons <kristaps@bsd.lv>
*
@@ -255,6 +255,9 @@ a2roffdeco(enum roffdeco *d, const char **word, size_t *sz)
case ('\''):
term = '\'';
break;
+ case ('0'):
+ j++;
+ /* FALLTHROUGH */
default:
i--;
lim = 1;