From owner-freebsd-hackers Mon Nov 18 19:13: 4 2002 Delivered-To: freebsd-hackers@freebsd.org Received: from mx1.FreeBSD.org (mx1.freebsd.org [216.136.204.125]) by hub.freebsd.org (Postfix) with ESMTP id E433037B401 for ; Mon, 18 Nov 2002 19:13:03 -0800 (PST) Received: from cauchy.axista.com (cauchy.superb.net [209.61.216.58]) by mx1.FreeBSD.org (Postfix) with ESMTP id 8A8E843E91 for ; Mon, 18 Nov 2002 19:13:03 -0800 (PST) (envelope-from cce@cauchy.axista.com) Received: by cauchy.axista.com (Postfix, from userid 1000) id B31EF6D0B1; Tue, 19 Nov 2002 03:20:23 +0000 (GMT) Date: Tue, 19 Nov 2002 03:20:23 +0000 From: "Clark C. Evans" To: freebsd-hackers@freebsd.org Subject: cd9660 and fcntl (shared locks) Message-ID: <20021119032023.GA54980@doublegemini.com> Mime-Version: 1.0 Content-Type: text/plain; charset=us-ascii Content-Disposition: inline User-Agent: Mutt/1.4i Sender: owner-freebsd-hackers@FreeBSD.ORG Precedence: bulk List-ID: List-Archive: (Web Archive) List-Help: (List Instructions) List-Subscribe: List-Unsubscribe: X-Loop: FreeBSD.ORG When I open a file mounted via cd9660 as O_RDONLY and then flock(fd,LOCK_SH) it returns invalid argument; is there a reason why the cd-rom file system can't just return success here, make flock a no-op that is always successful? There are many cases where you want general code to use shared locks on files opened for reading to make sure that it doesn't get changed during the read. This general code should be useable on file systems mounted read only. Thoughts? Is there an easy patch? Clark To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-hackers" in the body of the message