From owner-svn-src-all@FreeBSD.ORG Thu Dec 10 21:21:25 2009 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 761621065672; Thu, 10 Dec 2009 21:21:25 +0000 (UTC) (envelope-from brooks@lor.one-eyed-alien.net) Received: from lor.one-eyed-alien.net (lor.one-eyed-alien.net [69.66.77.232]) by mx1.freebsd.org (Postfix) with ESMTP id 0E13D8FC22; Thu, 10 Dec 2009 21:21:24 +0000 (UTC) Received: from lor.one-eyed-alien.net (localhost [127.0.0.1]) by lor.one-eyed-alien.net (8.14.3/8.14.3) with ESMTP id nBALK987023770; Thu, 10 Dec 2009 15:20:09 -0600 (CST) (envelope-from brooks@lor.one-eyed-alien.net) Received: (from brooks@localhost) by lor.one-eyed-alien.net (8.14.3/8.14.3/Submit) id nBALK9Is023769; Thu, 10 Dec 2009 15:20:09 -0600 (CST) (envelope-from brooks) Date: Thu, 10 Dec 2009 15:20:09 -0600 From: Brooks Davis To: Dmitry Pryanishnikov Message-ID: <20091210212009.GB23550@lor.one-eyed-alien.net> References: <4B146423.2090703@gmail.com> MIME-Version: 1.0 Content-Type: multipart/signed; micalg=pgp-sha1; protocol="application/pgp-signature"; boundary="+g7M9IMkV8truYOl" Content-Disposition: inline In-Reply-To: <4B146423.2090703@gmail.com> User-Agent: Mutt/1.5.17 (2007-11-01) X-Greylist: Sender IP whitelisted, not delayed by milter-greylist-3.0 (lor.one-eyed-alien.net [127.0.0.1]); Thu, 10 Dec 2009 15:20:09 -0600 (CST) Cc: svn-src-head@FreeBSD.org, svn-src-all@FreeBSD.org, src-committers@FreeBSD.org Subject: Re: svn commit: r195843 - in head: lib/libkvm sys/kern sys/sys 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: Thu, 10 Dec 2009 21:21:25 -0000 --+g7M9IMkV8truYOl Content-Type: text/plain; charset=us-ascii Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Tue, Dec 01, 2009 at 02:32:35AM +0200, Dmitry Pryanishnikov wrote: >=20 > Hello! >=20 >> Author: brooks >> Date: Fri Jul 24 15:03:10 2009 >> New Revision: 195843 >> URL: http://svn.freebsd.org/changeset/base/195843 >>=20 >> Log: >> Revert the changes to struct kinfo_proc in r194498. Instead, fill >> in up to 16 (KI_NGROUPS) values and steal a bit from ki_cr_flags >> (all bits currently unused) to indicate overflow with the new flag >> KI_CRF_GRP_OVERFLOW. >> This fixes procstat -s. >> Approved by: re (kib) >>=20 >> Modified: >> head/lib/libkvm/kvm_proc.c >> head/sys/kern/kern_proc.c >> head/sys/sys/user.h >>=20 >> Modified: head/lib/libkvm/kvm_proc.c >> =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D= =3D=3D=3D=3D >> --- head/lib/libkvm/kvm_proc.c Fri Jul 24 14:57:02 2009 (r195842) >> +++ head/lib/libkvm/kvm_proc.c Fri Jul 24 15:03:10 2009 (r195843) >> @@ -145,8 +145,14 @@ kvm_proclist(kd, what, arg, p, bp, maxcn >> kp->ki_svuid =3D ucred.cr_svuid; >> kp->ki_rgid =3D ucred.cr_rgid; >> kp->ki_svgid =3D ucred.cr_svgid; >> - kp->ki_ngroups =3D ucred.cr_ngroups; >> - kp->ki_groups =3D ucred.cr_groups; >> + kp->ki_cr_flags =3D ucred.cr_flags; >> + if (ucred.cr_ngroups > KI_NGROUPS) { >> + kp->ki_ngroups =3D KI_NGROUPS; >> + kp->ki_cr_flags |=3D KI_CRF_GRP_OVERFLOW; >> + } >> + kp->ki_ngroups =3D ucred.cr_ngroups; >=20 > It seems that 'else' is missing after closing brace of this 'if'? With = the > code as is, 'kp->ki_ngroups =3D KI_NGROUPS;' is effectively NO-OP... Yikes, you're right. Sorry I took so long to fix this. I'll MFC in about a week. -- Brooks --+g7M9IMkV8truYOl Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.4.9 (FreeBSD) iD8DBQFLIWYIXY6L6fI4GtQRArJqAJ9zqdPxxNUN2nmb+oVinJ5QDVUa9ACg3UrH 61YErVplE9LCo1ronCKvBk0= =bNfj -----END PGP SIGNATURE----- --+g7M9IMkV8truYOl--