fcntl(f, F_SETLK, &fl) problem on Cygwin 1.1.8(0.34/3/2)

Joerg Schilling schilling@fokus.gmd.de
Fri Mar 2 17:14:00 GMT 2001

>From: Christopher Faylor <cgf@redhat.com>

>On Wed, Feb 28, 2001 at 01:42:05PM +0100, schilling@fokus.gmd.de wrote:
>>It seems that a write lock on a file hold by a process
>>inhibits read access from the same process:

>And, your proposed fix is...?

>This is cygwin-developers, right?  We do cygwin development here.

OK, so let me ask a bit more precise:

VED (and similar nvi) does record locking of edited files by first
opening the file with O_RDWR and applying a record lock. Then it opens
the the file for reading and reads the file into the buffer.

This definitely does not work with Cygwin on Win ME. 

-	Will this work on Win NT ?

If not, I could try to re-use the file descriptor from the record
locking call for reading in the file and later for writing it out.
But then there should definitely a fix in cygwin or a hint in the FAQ.


 EMail:joerg@schily.isdn.cs.tu-berlin.de (home) Jörg Schilling D-13353 Berlin
       js@cs.tu-berlin.de		(uni)  If you don't have iso-8859-1
       schilling@fokus.gmd.de		(work) chars I am J"org Schilling
 URL:  http://www.fokus.gmd.de/usr/schilling   ftp://ftp.fokus.gmd.de/pub/unix

More information about the Cygwin-developers mailing list