Skip site navigation (1)Skip section navigation (2)
Date:      Thu, 23 Oct 1997 18:08:40 +0000 (GMT)
From:      Terry Lambert <tlambert@primenet.com>
To:        thorpej@nas.nasa.gov
Cc:        tlambert@primenet.com, dk+@ua.net, freebsd-hackers@freebsd.org
Subject:   Re: Possible SERIOUS bug in open()?
Message-ID:  <199710231808.LAA28324@usr02.primenet.com>
In-Reply-To: <199710231756.KAA04569@lestat.nas.nasa.gov> from "Jason Thorpe" at Oct 23, 97 10:56:17 am

next in thread | previous in thread | raw e-mail | index | archive | help
>  > I need to hold a reference.  The "lock against eject" operation is
>  > a side effect of an existing reference forcing the count over 1 for
>  > the device in question.
>  > 
>  > So the short answer is "to obtain reference side effects without
>  > granting read/write access on the descriptor".
> 
> I think "open for not read not write" is a silly way to do this, personally.
> 
> If you want to add/delete "artificial references", then invent a real
> interface for it, don't use a hack like open with non-sensical flags.

By this logic, locking should be implemented via a system call instead
of a hack like fcntl().  8-(.


					Terry Lambert
					terry@lambert.org
---
Any opinions in this posting are my own and not those of my present
or previous employers.



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