Date: Sun, 28 Mar 2004 10:10:02 +0200 From: Pawel Jakub Dawidek <pjd@FreeBSD.org> To: Robert Watson <rwatson@FreeBSD.org> Cc: cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/netinet in_pcb.c in_pcb.h ip_divert.c tcp_syncache.c tcp_usrreq.c udp_usrreq.c src/sys/netinet6 in6_pcb.c in6_pcb.h in6_src.c udp6_output.c udp6_usrreq.c Message-ID: <20040328081002.GW8930@darkness.comp.waw.pl> In-Reply-To: <Pine.NEB.3.96L.1040327214816.10933A-100000@fledge.watson.org> References: <4066159C.7030102@elischer.org> <Pine.NEB.3.96L.1040327214816.10933A-100000@fledge.watson.org>
next in thread | previous in thread | raw e-mail | index | archive | help
--5t1z8kqiv7KqGNMe Content-Type: text/plain; charset=iso-8859-2 Content-Disposition: inline Content-Transfer-Encoding: quoted-printable On Sat, Mar 27, 2004 at 09:52:57PM -0500, Robert Watson wrote: +> The credential is only used during the functions, and the reference is +> owned by the calling thread for the duration of the calls. This change +> basically moves the td->td_ucred dereference to the caller, rather than +> doing them in the function. It should be no less safe than the existing +> code, and since td_ucred is a thread-local reference, it should be safe +> assuming curthread=3D=3Dtd in the caller. The only place I've found, where curthread !=3D td, is NFS code, where thread0 is used instead of curthread, but it should be also safe. --=20 Pawel Jakub Dawidek http://www.FreeBSD.org pjd@FreeBSD.org http://garage.freebsd.pl FreeBSD committer Am I Evil? Yes, I Am! --5t1z8kqiv7KqGNMe Content-Type: application/pgp-signature Content-Disposition: inline -----BEGIN PGP SIGNATURE----- Version: GnuPG v1.2.4 (FreeBSD) iD8DBQFAZohaForvXbEpPzQRAk7uAJ9Al4JNVmgHJthnZq7jUjEezbETMQCgl+50 2C9uOrEdByAbX5oNd70TH+I= =tvhQ -----END PGP SIGNATURE----- --5t1z8kqiv7KqGNMe--
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?20040328081002.GW8930>