Date: Sat, 14 Aug 2004 16:59:59 -0400 (EDT) From: Robert Watson <rwatson@FreeBSD.org> To: Julian Elischer <julian@elischer.org> Cc: cvs-all@FreeBSD.org Subject: Re: cvs commit: src/sys/kern kern_proc.c Message-ID: <Pine.NEB.3.96L.1040814165922.30898A-100000@fledge.watson.org> In-Reply-To: <411E7CD4.7010504@elischer.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Sat, 14 Aug 2004, Julian Elischer wrote: > > Cause pfind() not to return processes in the PRS_NEW state. As a result, > > threads consuming the result of pfind() will not need to check for a NULL > > credential pointer or other signs of an incompletely created process. > > However, this also means that pfind() cannot be used to test for the > > existence or find such a process. Annotate pfind() to indicate that this > > is the case. A review of curent consumers seems to indicate that this is > > not a problem for any of them. This closes a number of race conditions > > that could result in NULL pointer dereferences and related failure modes. > > Other related races continue to exist, especially during iteration of the > > allproc list without due caution. > > possibly part of the answer would be to not put the proc on any queues > until it is more set up.. Tim had a set of modifications to keep them on a separate list, but I think he also decided it was quite a bit more complicated than they had hoped. Robert N M Watson FreeBSD Core Team, TrustedBSD Projects robert@fledge.watson.org Principal Research Scientist, McAfee Research
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.NEB.3.96L.1040814165922.30898A-100000>