Date: Thu, 29 Jun 2006 14:18:54 GMT From: John Baldwin <jhb@FreeBSD.org> To: Perforce Change Reviews <perforce@freebsd.org> Subject: PERFORCE change 100289 for review Message-ID: <200606291418.k5TEIsLF068849@repoman.freebsd.org>
next in thread | raw e-mail | index | archive | help
http://perforce.freebsd.org/chv.cgi?CH=100289 Change 100289 by jhb@jhb_mutex on 2006/06/29 14:18:32 Compile and other nits. Affected files ... .. //depot/projects/smpng/sys/i386/ibcs2/ibcs2_misc.c#26 edit .. //depot/projects/smpng/sys/kern/kern_prot.c#95 edit Differences ... ==== //depot/projects/smpng/sys/i386/ibcs2/ibcs2_misc.c#26 (text+ko) ==== @@ -653,7 +653,8 @@ { ibcs2_gid_t iset[NGROUPS_MAX]; gid_t gp[NGROUPS_MAX]; - int error, i, ngrp; + u_int i, ngrp; + int error; if (uap->gidsetsize < 0) return (EINVAL); ==== //depot/projects/smpng/sys/kern/kern_prot.c#95 (text+ko) ==== @@ -300,7 +300,8 @@ getgroups(struct thread *td, register struct getgroups_args *uap) { gid_t groups[NGROUPS]; - int error, ngrp; + u_int ngrp; + int error; ngrp = MIN(uap->gidsetsize, NGROUPS); error = kern_getgroups(td, &ngrp, groups); @@ -317,7 +318,6 @@ kern_getgroups(struct thread *td, u_int *ngrp, gid_t *groups) { struct ucred *cred; - int error; cred = td->td_ucred; if (*ngrp == 0) { @@ -327,7 +327,7 @@ if (*ngrp < cred->cr_ngroups) return (EINVAL); *ngrp = cred->cr_ngroups; - bcopy(cred->cr_groups, gidset, ngrp * sizeof(gid_t)); + bcopy(cred->cr_groups, groups, *ngrp * sizeof(gid_t)); return (0); }
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200606291418.k5TEIsLF068849>