diff options
author | 2018-12-14 05:18:02 +0000 | |
---|---|---|
committer | 2018-12-14 05:18:02 +0000 | |
commit | 7a6eb8920bdea2ecc151b308352b2a98699b2350 (patch) | |
tree | 9860a766930f3997c413b0f0aecd6ba815b80f25 /mandoc_msg.c | |
parent | 0ef6626fcc16277d2fefb32e1830dfba3df5defd (diff) | |
download | mandoc-7a6eb8920bdea2ecc151b308352b2a98699b2350.tar.gz mandoc-7a6eb8920bdea2ecc151b308352b2a98699b2350.tar.zst mandoc-7a6eb8920bdea2ecc151b308352b2a98699b2350.zip |
Almost mechanical diff to remove the "struct mparse *" argument
from mandoc_msg(), where it is no longer used.
While here, rename mandoc_vmsg() to mandoc_msg() and retire the
old version: There is really no point in having another function
merely to save "%s" in a few places.
Minus 140 lines of code.
Diffstat (limited to 'mandoc_msg.c')
-rw-r--r-- | mandoc_msg.c | 12 |
1 files changed, 1 insertions, 11 deletions
diff --git a/mandoc_msg.c b/mandoc_msg.c index aa0cce5a..d2ccb91f 100644 --- a/mandoc_msg.c +++ b/mandoc_msg.c @@ -288,8 +288,7 @@ mandoc_msg_setrc(enum mandoclevel level) } void -mandoc_vmsg(enum mandocerr t, void *dummy, int line, int col, - const char *fmt, ...) +mandoc_msg(enum mandocerr t, int line, int col, const char *fmt, ...) { va_list ap; enum mandoclevel level; @@ -324,12 +323,3 @@ mandoc_vmsg(enum mandocerr t, void *dummy, int line, int col, } fputc('\n', fileptr); } - -void -mandoc_msg(enum mandocerr t, void *dummy, int line, int col, const char *msg) -{ - if (msg == NULL) - mandoc_vmsg(t, dummy, line, col, NULL); - else - mandoc_vmsg(t, dummy, line, col, "%s", msg); -} |