summaryrefslogtreecommitdiffstats
path: root/mdocml.c
diff options
context:
space:
mode:
authorKristaps Dzonsons <kristaps@bsd.lv>2009-02-20 11:04:23 +0000
committerKristaps Dzonsons <kristaps@bsd.lv>2009-02-20 11:04:23 +0000
commit9ca2c862d8cd73c34a7a1b8ceee8eb45c3115d5a (patch)
treef662e0af14e89eea55ff25935c553b76991418b3 /mdocml.c
parent0d0191e1509b75f09a185c0ecd6600b832ff9bcc (diff)
downloadmandoc-9ca2c862d8cd73c34a7a1b8ceee8eb45c3115d5a.tar.gz
Re-added tree.c (for now).
Added initial terminal-output filter (term.c).
Diffstat (limited to 'mdocml.c')
-rw-r--r--mdocml.c8
1 files changed, 3 insertions, 5 deletions
diff --git a/mdocml.c b/mdocml.c
index f76ee0b5..8c77b1e2 100644
--- a/mdocml.c
+++ b/mdocml.c
@@ -224,6 +224,8 @@ buf_begin(struct md_parse *p)
static int
parse_leave(struct md_parse *p, int code)
{
+ extern int termprint(const struct mdoc_node *,
+ const struct mdoc_meta *);
if (NULL == p->mdoc)
return(code);
@@ -231,13 +233,9 @@ parse_leave(struct md_parse *p, int code)
if ( ! mdoc_endparse(p->mdoc))
code = 0;
-#if 0
/* TODO */
- if (code && ! mdoc_write(p->out, mdoc_node(p->mdoc))) {
- warnx("%s: write error", p->out);
+ if (code && ! termprint(mdoc_node(p->mdoc), mdoc_meta(p->mdoc)))
code = 0;
- }
-#endif
mdoc_free(p->mdoc);
return(code);