Skip site navigation (1)Skip section navigation (2)
Date:      Mon, 19 Jan 2004 19:30:18 -0800 (PST)
From:      David Schultz <das@FreeBSD.ORG>
To:        freebsd-bugs@FreeBSD.org
Subject:   Re: bin/60758: cycle-eating endless loop in lock(1)
Message-ID:  <200401200330.i0K3UIUM038513@freefall.freebsd.org>

next in thread | raw e-mail | index | archive | help
The following reply was made to PR bin/60758; it has been noted by GNATS.

From: David Schultz <das@FreeBSD.ORG>
To: Colin Percival <cperciva@daemonology.net>
Cc: FreeBSD-gnats-submit@FreeBSD.ORG
Subject: Re: bin/60758: cycle-eating endless loop in lock(1)
Date: Mon, 19 Jan 2004 19:22:41 -0800

 On Wed, Dec 31, 2003, Colin Percival wrote:
 > Insert a sleep(1) call into the endless loop.  This still leaves an orphan 
 > lying around, but since lock is important for security purposes, this is 
 > probably safer than exiting.
 
 As you observe, it's not a good idea to exit the loop.  On the
 other hand, fgets(3) errors are generally not recoverable, so
 calling sleep(1) seems a bit kludgy.  How about just calling
 pause(3) if an error occurs?



Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200401200330.i0K3UIUM038513>