From owner-svn-src-all@FreeBSD.ORG Wed Oct 3 20:39:11 2012 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id D7C591065670; Wed, 3 Oct 2012 20:39:11 +0000 (UTC) (envelope-from pfg@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id C38248FC12; Wed, 3 Oct 2012 20:39:11 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.4/8.14.4) with ESMTP id q93KdB6C089734; Wed, 3 Oct 2012 20:39:11 GMT (envelope-from pfg@svn.freebsd.org) Received: (from pfg@localhost) by svn.freebsd.org (8.14.4/8.14.4/Submit) id q93KdBOr089732; Wed, 3 Oct 2012 20:39:11 GMT (envelope-from pfg@svn.freebsd.org) Message-Id: <201210032039.q93KdBOr089732@svn.freebsd.org> From: "Pedro F. Giffuni" Date: Wed, 3 Oct 2012 20:39:11 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r241165 - head/lib/libc/rpc X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Wed, 03 Oct 2012 20:39:12 -0000 Author: pfg Date: Wed Oct 3 20:39:11 2012 New Revision: 241165 URL: http://svn.freebsd.org/changeset/base/241165 Log: 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 Modified: head/lib/libc/rpc/authunix_prot.c Modified: head/lib/libc/rpc/authunix_prot.c ============================================================================== --- head/lib/libc/rpc/authunix_prot.c Wed Oct 3 17:20:34 2012 (r241164) +++ head/lib/libc/rpc/authunix_prot.c Wed Oct 3 20:39:11 2012 (r241165) @@ -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);