Relay-Version: version B 2.10 5/3/83; site utzoo.UUCP Path: utzoo!mnetor!seismo!ut-sally!utah-cs!utah-gr!thomas From: thomas@utah-gr.UUCP (Spencer W. Thomas) Newsgroups: comp.unix.wizards Subject: Re: lockf and the SVID, (Was "Re: Wanted: lockf system call source") Message-ID: <1860@utah-gr.UUCP> Date: Tue, 2-Dec-86 12:00:12 EST Article-I.D.: utah-gr.1860 Posted: Tue Dec 2 12:00:12 1986 Date-Received: Tue, 2-Dec-86 20:30:03 EST References: <5413@brl-smoke.ARPA> <2264@sdcsvax.UCSD.EDU> Reply-To: thomas@utah-gr.UUCP (Spencer W. Thomas) Organization: University of Utah CS Dept Lines: 9 Why would you require a file open for write to set a write lock? Consider the following scenario: fd = open( "/etc/passwd", 0 ); /* this is ok */ lock_for_write( fd ); /* Not so good, eh? */ sleep( 1000000000 ); /* Now try to change your password */ -- =Spencer ({ihnp4,decvax}!utah-cs!thomas, thomas@utah-cs.ARPA)