diff options
author | Garance A Drosehn <gad@FreeBSD.org> | 2001-07-15 00:09:46 +0000 |
---|---|---|
committer | Garance A Drosehn <gad@FreeBSD.org> | 2001-07-15 00:09:46 +0000 |
commit | 6d39e1b726e54b78521fac365221574a6368a780 (patch) | |
tree | 72f0a137b622cd6dc694bb199a12a08fd1b19169 /usr.sbin/lpr/lpd/printjob.c | |
parent | 2a57c11a3ae6cc9c8b7f0a757857b55da7bbc23a (diff) |
Fix most of the warnings generated by compiling lpr with -Wnon-const-format,
often by just telling gcc that some internal routine is "__printflike"
(work done by Kris Kennaway <kris@FreeBSD.org>). Also fix the new warnings
which show up once gcc starts checking the "printf-like parameters" passed
to those routines.
MFC after: 1 week
Notes
Notes:
svn path=/head/; revision=79739
Diffstat (limited to 'usr.sbin/lpr/lpd/printjob.c')
-rw-r--r-- | usr.sbin/lpr/lpd/printjob.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/usr.sbin/lpr/lpd/printjob.c b/usr.sbin/lpr/lpd/printjob.c index d2705c3278f6..e2ce3eaca9ec 100644 --- a/usr.sbin/lpr/lpd/printjob.c +++ b/usr.sbin/lpr/lpd/printjob.c @@ -133,7 +133,8 @@ static void opentty(const struct printer *_pp); static void openrem(const struct printer *pp); static int print(struct printer *_pp, int _format, char *_file); static int printit(struct printer *_pp, char *_file); -static void pstatus(const struct printer *_pp, const char *_msg, ...); +static void pstatus(const struct printer *_pp, const char *_msg, ...) + __printflike(2, 3); static char response(const struct printer *_pp); static void scan_out(struct printer *_pp, int _scfd, char *_scsp, int _dlm); @@ -1605,7 +1606,7 @@ opennet(const struct printer *pp) } sleep(i); } - pstatus(pp, "sending to %s port %d", ep, port); + pstatus(pp, "sending to %s port %lu", ep, port); } /* |