aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/roff_term.c
diff options
context:
space:
mode:
authorIngo Schwarze <schwarze@openbsd.org>2017-06-08 12:54:58 +0000
committerIngo Schwarze <schwarze@openbsd.org>2017-06-08 12:54:58 +0000
commit789580a2a2366243d622766fdadd094931ca6596 (patch)
tree60a78614bcfb83b55ebd45464a5bc77e4c61c98c /roff_term.c
parent76a6887f123b221e7a8851c1b0d0008119492613 (diff)
downloadmandoc-789580a2a2366243d622766fdadd094931ca6596.tar.gz
mandoc-789580a2a2366243d622766fdadd094931ca6596.tar.zst
mandoc-789580a2a2366243d622766fdadd094931ca6596.zip
make the internal a2roffsu() interface more powerful by returning
a pointer to the end of the parsed data, making it easier to parse subsequent bytes
Diffstat (limited to 'roff_term.c')
-rw-r--r--roff_term.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/roff_term.c b/roff_term.c
index 3240b93e..7574102b 100644
--- a/roff_term.c
+++ b/roff_term.c
@@ -1,4 +1,4 @@
-/* $Id: roff_term.c,v 1.9 2017/06/07 17:38:26 schwarze Exp $ */
+/* $Id: roff_term.c,v 1.10 2017/06/08 12:54:58 schwarze Exp $ */
/*
* Copyright (c) 2010, 2014, 2015, 2017 Ingo Schwarze <schwarze@openbsd.org>
*
@@ -157,7 +157,7 @@ roff_term_pre_sp(ROFF_TERM_ARGS)
int len;
if (n->child != NULL) {
- if (a2roffsu(n->child->string, &su, SCALE_VS) == 0)
+ if (a2roffsu(n->child->string, &su, SCALE_VS) == NULL)
su.scale = 1.0;
len = term_vspan(p, &su);
} else
@@ -201,7 +201,7 @@ roff_term_pre_ti(ROFF_TERM_ARGS)
} else
sign = 0;
- if (a2roffsu(cp, &su, SCALE_EM) == 0)
+ if (a2roffsu(cp, &su, SCALE_EM) == NULL)
return;
len = term_hspan(p, &su) / 24;