diff options
author | 2014-06-20 16:11:03 +0000 | |
---|---|---|
committer | 2014-06-20 16:11:03 +0000 | |
commit | 8b5dcd070dc6de270fd297aa8a7a019a6e480b5f (patch) | |
tree | 3af0dfd184bf23359c0a945e14fb7fbbc0ebf84e | |
parent | Remove OPENSSL_instrument_halt and OPENSSL_far_spin, which both might (diff) | |
download | wireguard-openbsd-8b5dcd070dc6de270fd297aa8a7a019a6e480b5f.tar.xz wireguard-openbsd-8b5dcd070dc6de270fd297aa8a7a019a6e480b5f.zip |
Prefix error messages from mandoc(1) with "mandoc: "
just like almost all other utility programs do.
Suggested by nick@ who wondered where messages came from
when calling mandoc(1) from inside a Perl script.
ok jmc@ nick@
-rw-r--r-- | usr.bin/mandoc/main.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.bin/mandoc/main.c b/usr.bin/mandoc/main.c index e62efcb5e18..b0b35319bed 100644 --- a/usr.bin/mandoc/main.c +++ b/usr.bin/mandoc/main.c @@ -1,4 +1,4 @@ -/* $Id: main.c,v 1.90 2014/04/20 16:44:44 schwarze Exp $ */ +/* $Id: main.c,v 1.91 2014/06/20 16:11:03 schwarze Exp $ */ /* * Copyright (c) 2008, 2009, 2010, 2011 Kristaps Dzonsons <kristaps@bsd.lv> * Copyright (c) 2010, 2011, 2012, 2014 Ingo Schwarze <schwarze@openbsd.org> @@ -409,7 +409,8 @@ mmsg(enum mandocerr t, enum mandoclevel lvl, const char *file, int line, int col, const char *msg) { - fprintf(stderr, "%s:%d:%d: %s: %s", file, line, col + 1, + fprintf(stderr, "%s: %s:%d:%d: %s: %s", progname, + file, line, col + 1, mparse_strlevel(lvl), mparse_strerror(t)); if (msg) |