summaryrefslogtreecommitdiffstats
path: root/lib/libc/rpc
diff options
context:
space:
mode:
authorpfg <pfg@FreeBSD.org>2012-10-03 20:39:11 +0000
committerpfg <pfg@FreeBSD.org>2012-10-03 20:39:11 +0000
commitfc02898d2b53483e0c3e7ac6b4d1520e27365095 (patch)
treed28660cfbcdbb34571b8d4447341dd0350cf4620 /lib/libc/rpc
parentcecfb309c72bbfaffe0aaa2af2f2609d9b05d327 (diff)
downloadFreeBSD-src-fc02898d2b53483e0c3e7ac6b4d1520e27365095.zip
FreeBSD-src-fc02898d2b53483e0c3e7ac6b4d1520e27365095.tar.gz
rpc: convert all uid and gid variables of the type uid_t and gid_t.
The previous change (based on Solaris) doesn't work properly either as the casting only has the effect of quieting the compiler. Move back to the previous solution but adjust the sizeof() type in xdr_array(). This should mostly work (by accident). Reported by: bde
Diffstat (limited to 'lib/libc/rpc')
-rw-r--r--lib/libc/rpc/authunix_prot.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/libc/rpc/authunix_prot.c b/lib/libc/rpc/authunix_prot.c
index 437c331..36311e8 100644
--- a/lib/libc/rpc/authunix_prot.c
+++ b/lib/libc/rpc/authunix_prot.c
@@ -69,10 +69,10 @@ xdr_authunix_parms(xdrs, p)
if (xdr_u_long(xdrs, &(p->aup_time)) &&
xdr_string(xdrs, &(p->aup_machname), MAX_MACHINE_NAME) &&
- xdr_int(xdrs, (int *) &(p->aup_uid)) &&
- xdr_int(xdrs, (int *) &(p->aup_gid)) &&
+ xdr_u_int(xdrs, &(p->aup_uid)) &&
+ xdr_u_int(xdrs, &(p->aup_gid)) &&
xdr_array(xdrs, (char **) paup_gids,
- &(p->aup_len), NGRPS, sizeof(int), (xdrproc_t)xdr_int) ) {
+ &(p->aup_len), NGRPS, sizeof(gid_t), (xdrproc_t)xdr_int) ) {
return (TRUE);
}
return (FALSE);
OpenPOWER on IntegriCloud