From 223727dbba0bff013b3bacc8607570b2b41667c1 Mon Sep 17 00:00:00 2001 From: Ingo Schwarze Date: Fri, 20 Aug 2010 08:13:43 +0000 Subject: fix previous: when bailing out due to -Wstop, skip output functions, but not *_endparse; problem reported by kristaps@ --- main.c | 18 +++++++++--------- 1 file changed, 9 insertions(+), 9 deletions(-) (limited to 'main.c') diff --git a/main.c b/main.c index 1e635fe2..044ec79f 100644 --- a/main.c +++ b/main.c @@ -1,4 +1,4 @@ -/* $Id: main.c,v 1.103 2010/08/20 01:02:07 schwarze Exp $ */ +/* $Id: main.c,v 1.104 2010/08/20 08:13:43 schwarze Exp $ */ /* * Copyright (c) 2008, 2009, 2010 Kristaps Dzonsons * Copyright (c) 2010 Ingo Schwarze @@ -551,14 +551,6 @@ fdesc(struct curparse *curp) } } - /* - * With -Wstop and warnings or errors of at least - * the requested level, do not produce output. - */ - - if (MANDOCLEVEL_OK != exit_status && curp->wstop) - goto cleanup; - /* NOTE a parser may not have been assigned, yet. */ if ( ! (man || mdoc)) { @@ -582,6 +574,14 @@ fdesc(struct curparse *curp) goto cleanup; } + /* + * With -Wstop and warnings or errors of at least + * the requested level, do not produce output. + */ + + if (MANDOCLEVEL_OK != exit_status && curp->wstop) + goto cleanup; + /* If unset, allocate output dev now (if applicable). */ if ( ! (curp->outman && curp->outmdoc)) { -- cgit v1.2.3-56-ge451