summaryrefslogtreecommitdiffstats
path: root/main.c
diff options
context:
space:
mode:
Diffstat (limited to 'main.c')
-rw-r--r--main.c11
1 files changed, 5 insertions, 6 deletions
diff --git a/main.c b/main.c
index 84bccdf5..b8c5aa33 100644
--- a/main.c
+++ b/main.c
@@ -418,7 +418,7 @@ fdesc(struct buf *blk, struct buf *ln, struct curparse *curp)
/* NOTE a parser may not have been assigned, yet. */
if ( ! (man || mdoc)) {
- warnx("%s: not a manual", curp->file);
+ (void)fprintf(stderr, "%s: not a manual", curp->file);
return(0);
}
@@ -639,8 +639,8 @@ merr(void *arg, int line, int col, const char *msg)
curp = (struct curparse *)arg;
- warnx("%s:%d: error: %s (column %d)",
- curp->file, line, msg, col);
+ (void)fprintf(stderr, "%s:%d:%d: error: %s\n",
+ curp->file, line, col + 1, msg);
return(0);
}
@@ -656,13 +656,12 @@ mwarn(void *arg, int line, int col, const char *msg)
if ( ! (curp->wflags & WARN_WALL))
return(1);
- warnx("%s:%d: warning: %s (column %d)",
- curp->file, line, msg, col);
+ (void)fprintf(stderr, "%s:%d:%d: warning: %s\n",
+ curp->file, line, col + 1, msg);
if ( ! (curp->wflags & WARN_WERR))
return(1);
- warnx("considering warnings as errors");
return(0);
}