Date: Fri, 23 Feb 2001 07:12:04 -0500 (EST) From: Daniel Eischen <eischen@vigrid.com> To: Brian Feldman <green@FreeBSD.org> Cc: cvs-committers@FreeBSD.org, cvs-all@FreeBSD.org Subject: Re: cvs commit: src/lib/libc/stdio _flock_stub.c Message-ID: <Pine.SUN.3.91.1010223070829.2982A-100000@pcnet1.pcnet.com> In-Reply-To: <200102230459.f1N4xE197992@freefall.freebsd.org>
next in thread | previous in thread | raw e-mail | index | archive | help
On Thu, 22 Feb 2001, Brian Feldman wrote: > green 2001/02/22 20:59:13 PST > > Modified files: > lib/libc/stdio _flock_stub.c > Log: > Fix the problems I (and others, undoubtedly) have been having for a > while with threaded software in -CURRENT acting very "weird". It has > seemed, for example, in Mozilla that threads attempting to do host > lookups have been locking up. That's exactly the case. > > There was a race condition in the implementation of the initialization > of the mutex used to protect FILE operations, first of all: multiple > instances of FLOCKFILE() in libc could occur on the same FILE at > the same time and cause strange behavior by overwriting eachothers' > creation of the mutex and the rest of the file lock. I knew about this and was going to change it so that struct __file_lock is allocated along with _extra in findfp.c. This would eliminate the race condition and the need to have another mutex. -- Dan Eischen To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe cvs-all" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?Pine.SUN.3.91.1010223070829.2982A-100000>