diff options
author | Kristaps Dzonsons <kristaps@bsd.lv> | 2011-03-22 10:35:26 +0000 |
---|---|---|
committer | Kristaps Dzonsons <kristaps@bsd.lv> | 2011-03-22 10:35:26 +0000 |
commit | d7ddf4463ca2aeccf4afd41006e86ebf22df6529 (patch) | |
tree | 17458d2ad2c7a6aeca8d7c0cd742714ea7b657ef /read.c | |
parent | 643580914487cde30df4724b8d2650d81470351f (diff) | |
download | mandoc-d7ddf4463ca2aeccf4afd41006e86ebf22df6529.tar.gz |
Add a FATAL error for when no manual type was assigned (you can repeat
this for yourself by having a file consisting only of comments).
Diffstat (limited to 'read.c')
-rw-r--r-- | read.c | 9 |
1 files changed, 2 insertions, 7 deletions
@@ -496,16 +496,11 @@ mparse_end(struct mparse *curp) return; } -#if 0 - /* FIXME: NOTE a parser may not have been assigned, yet. */ - if ( ! (curp->man || curp->mdoc)) { - /* FIXME: make into an mandoc.h error. */ - fprintf(stderr, "%s: Not a manual\n", curp->file); + mandoc_msg(MANDOCERR_NOTMANUAL, curp, 1, 0, NULL); curp->file_status = MANDOCLEVEL_FATAL; - goto cleanup; + return; } -#endif roff_endparse(curp->roff); } |