From 5b0d3e5eb36fe261cdbf8fadcaa5598a7a1d6fd2 Mon Sep 17 00:00:00 2001 From: Sascha Wildner Date: Tue, 30 Dec 2008 16:35:10 +0100 Subject: [PATCH] Fix some WARNS6 regression that crept up in the last days. --- bin/ps/print.c | 1 + bin/rm/rm.c | 2 ++ contrib/smbfs/smbutil/dumptree.c | 2 ++ libexec/rpc.rquotad/rquotad.c | 8 ++++---- usr.bin/lastcomm/lastcomm.c | 1 + usr.bin/systat/pigs.c | 2 +- 6 files changed, 11 insertions(+), 5 deletions(-) diff --git a/bin/ps/print.c b/bin/ps/print.c index 71510bd3c8..d5e582c404 100644 --- a/bin/ps/print.c +++ b/bin/ps/print.c @@ -51,6 +51,7 @@ #include #include #include +#include #include #include #include diff --git a/bin/rm/rm.c b/bin/rm/rm.c index 514b3f1d02..47529b5f2b 100644 --- a/bin/rm/rm.c +++ b/bin/rm/rm.c @@ -45,6 +45,8 @@ #include #include #include +#include +#include #include #include #include diff --git a/contrib/smbfs/smbutil/dumptree.c b/contrib/smbfs/smbutil/dumptree.c index 7d06142c3b..2ae383318e 100644 --- a/contrib/smbfs/smbutil/dumptree.c +++ b/contrib/smbfs/smbutil/dumptree.c @@ -1,5 +1,7 @@ #include #include +#include +#include #include #include #include diff --git a/libexec/rpc.rquotad/rquotad.c b/libexec/rpc.rquotad/rquotad.c index a450a66e78..e7f6d05847 100644 --- a/libexec/rpc.rquotad/rquotad.c +++ b/libexec/rpc.rquotad/rquotad.c @@ -112,7 +112,7 @@ rquota_service(struct svc_req *request, SVCXPRT *transp) { switch (request->rq_proc) { case NULLPROC: - (void)svc_sendreply(transp, xdr_void, (char *)NULL); + (void)svc_sendreply(transp, (xdrproc_t)xdr_void, (char *)NULL); break; case RQUOTAPROC_GETQUOTA: @@ -138,7 +138,7 @@ sendquota(struct svc_req *request, SVCXPRT *transp) struct timeval timev; bzero((char *)&getq_args, sizeof(getq_args)); - if (!svc_getargs(transp, xdr_getquota_args, (caddr_t)&getq_args)) { + if (!svc_getargs(transp, (xdrproc_t)xdr_getquota_args, (caddr_t)&getq_args)) { svcerr_decode(transp); return; } @@ -170,10 +170,10 @@ sendquota(struct svc_req *request, SVCXPRT *transp) getq_rslt.getquota_rslt_u.gqr_rquota.rq_ftimeleft = dqblk.dqb_itime - timev.tv_sec; } - if (!svc_sendreply(transp, xdr_getquota_rslt, (char *)&getq_rslt)) { + if (!svc_sendreply(transp, (xdrproc_t)xdr_getquota_rslt, (char *)&getq_rslt)) { svcerr_systemerr(transp); } - if (!svc_freeargs(transp, xdr_getquota_args, (caddr_t)&getq_args)) { + if (!svc_freeargs(transp, (xdrproc_t)xdr_getquota_args, (caddr_t)&getq_args)) { syslog(LOG_ERR, "unable to free arguments"); exit(1); } diff --git a/usr.bin/lastcomm/lastcomm.c b/usr.bin/lastcomm/lastcomm.c index 4ca00dba3d..a5e83e950d 100644 --- a/usr.bin/lastcomm/lastcomm.c +++ b/usr.bin/lastcomm/lastcomm.c @@ -43,6 +43,7 @@ #include #include #include +#include #include #include #include diff --git a/usr.bin/systat/pigs.c b/usr.bin/systat/pigs.c index e8e38f37c2..1ac9fcac13 100644 --- a/usr.bin/systat/pigs.c +++ b/usr.bin/systat/pigs.c @@ -124,7 +124,7 @@ showpigs(void) uname = ""; pname = ""; } else { - uname = (char *)user_from_uid(pt[k].pt_kp->kp_uid, 0); + uname = user_from_uid(pt[k].pt_kp->kp_uid, 0); pname = pt[k].pt_kp->kp_comm; } wmove(wnd, y, 0); -- 2.41.0