summaryrefslogtreecommitdiff
path: root/include
diff options
context:
space:
mode:
authorplunky <plunky@NetBSD.org>2011-08-30 17:06:20 +0000
committerplunky <plunky@NetBSD.org>2011-08-30 17:06:20 +0000
commit3cd9f110a3b5d823dfa855b36c0a0b3ca97faa0b (patch)
tree36b768fff008b683b52a411eae1f23e5e8fbb47f /include
parentd978656c4d2c9d76d838899f16b846bdfce60bfb (diff)
Apply casts to cases where xdrproc_t is expected but is not
strictly passed, for example because the second argument is a different kind of pointer.
Diffstat (limited to 'include')
-rw-r--r--include/rpc/clnt.h12
-rw-r--r--include/rpc/svc.h10
2 files changed, 12 insertions, 10 deletions
diff --git a/include/rpc/clnt.h b/include/rpc/clnt.h
index 557f78bd2a6..48707b2b447 100644
--- a/include/rpc/clnt.h
+++ b/include/rpc/clnt.h
@@ -1,4 +1,4 @@
-/* $NetBSD: clnt.h,v 1.20 2005/12/03 15:16:19 yamt Exp $ */
+/* $NetBSD: clnt.h,v 1.21 2011/08/30 17:06:20 plunky Exp $ */
/*
* Sun RPC is a product of Sun Microsystems, Inc. and is provided for
@@ -206,11 +206,13 @@ struct rpc_timers {
* struct timeval timeout;
*/
#define CLNT_CALL(rh, proc, xargs, argsp, xres, resp, secs) \
- ((*(rh)->cl_ops->cl_call)(rh, proc, xargs, \
- (const char *)(const void *)(argsp), xres, (caddr_t)(void *)resp, secs))
+ ((*(rh)->cl_ops->cl_call)(rh, proc, (xdrproc_t)xargs, \
+ (const char *)(const void *)(argsp), (xdrproc_t)xres, \
+ (caddr_t)(void *)resp, secs))
#define clnt_call(rh, proc, xargs, argsp, xres, resp, secs) \
- ((*(rh)->cl_ops->cl_call)(rh, proc, xargs, \
- (const char *)(const void *)(argsp), xres, (caddr_t)(void *)resp, secs))
+ ((*(rh)->cl_ops->cl_call)(rh, proc, (xdrproc_t)xargs, \
+ (const char *)(const void *)(argsp), (xdrproc_t)xres, \
+ (caddr_t)(void *)resp, secs))
/*
* void
diff --git a/include/rpc/svc.h b/include/rpc/svc.h
index 93fb4b06b9f..10f4a64d0c1 100644
--- a/include/rpc/svc.h
+++ b/include/rpc/svc.h
@@ -1,4 +1,4 @@
-/* $NetBSD: svc.h,v 1.23 2005/12/26 19:01:47 perry Exp $ */
+/* $NetBSD: svc.h,v 1.24 2011/08/30 17:06:20 plunky Exp $ */
/*
* Sun RPC is a product of Sun Microsystems, Inc. and is provided for
@@ -163,9 +163,9 @@ struct svc_req {
(*(xprt)->xp_ops->xp_stat)(xprt)
#define SVC_GETARGS(xprt, xargs, argsp) \
- (*(xprt)->xp_ops->xp_getargs)((xprt), (xargs), (argsp))
+ (*(xprt)->xp_ops->xp_getargs)((xprt), ((xdrproc_t)(xargs)), (argsp))
#define svc_getargs(xprt, xargs, argsp) \
- (*(xprt)->xp_ops->xp_getargs)((xprt), (xargs), (argsp))
+ (*(xprt)->xp_ops->xp_getargs)((xprt), ((xdrproc_t)(xargs)), (argsp))
#define SVC_REPLY(xprt, msg) \
(*(xprt)->xp_ops->xp_reply) ((xprt), (msg))
@@ -173,9 +173,9 @@ struct svc_req {
(*(xprt)->xp_ops->xp_reply) ((xprt), (msg))
#define SVC_FREEARGS(xprt, xargs, argsp) \
- (*(xprt)->xp_ops->xp_freeargs)((xprt), (xargs), (argsp))
+ (*(xprt)->xp_ops->xp_freeargs)((xprt), ((xdrproc_t)(xargs)), (argsp))
#define svc_freeargs(xprt, xargs, argsp) \
- (*(xprt)->xp_ops->xp_freeargs)((xprt), (xargs), (argsp))
+ (*(xprt)->xp_ops->xp_freeargs)((xprt), ((xdrproc_t)(xargs)), (argsp))
#define SVC_DESTROY(xprt) \
(*(xprt)->xp_ops->xp_destroy)(xprt)