From owner-freebsd-current Tue Feb 19 0:10:42 2002 Delivered-To: freebsd-current@freebsd.org Received: from albatross.prod.itd.earthlink.net (albatross.mail.pas.earthlink.net [207.217.120.120]) by hub.freebsd.org (Postfix) with ESMTP id 1FE1B37B417 for ; Tue, 19 Feb 2002 00:10:37 -0800 (PST) Received: from pool0367.cvx21-bradley.dialup.earthlink.net ([209.179.193.112] helo=mindspring.com) by albatross.prod.itd.earthlink.net with esmtp (Exim 3.33 #1) id 16d5Ln-0006UU-00; Tue, 19 Feb 2002 00:10:11 -0800 Message-ID: <3C720859.C77590F0@mindspring.com> Date: Tue, 19 Feb 2002 00:10:01 -0800 From: Terry Lambert X-Mailer: Mozilla 4.7 [en]C-CCK-MCD {Sony} (Win98; U) X-Accept-Language: en MIME-Version: 1.0 To: Julian Elischer Cc: Matthew Dillon , Peter Wemm , current@FreeBSD.ORG Subject: Re: Patch sets to date and timing tests with Giant out of userret. References: Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Sender: owner-freebsd-current@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG Julian Elischer wrote: > The fully safe version of this code is: > td->td_retval[0] = td->td_ucred->cr_ruid; > td->td_retval[1] = td->td_ucred->cr_uid; > return (0); > > because td->td_ucred is read-only for it's whole existance. ??? Are you sure that td->td_ucred can't change in the middle, to point to a different ucred, as a result of kernel preemption? -- Terry To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message