httpd-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Ryan Bloom <...@raleigh.ibm.com>
Subject Re: cvs commit: apache-apr/apr/test testfile.c
Date Mon, 07 Jun 1999 14:28:40 GMT

> >I don't like this.  I would rather have the file flushed each time data is
> >written to it, than have to close the file to update the directory update.
> >I saw this same problem on Windows, and I just decided to flush the
> >buffer.  IMHO, the OS is broken if it is buffering output to a file, but
> >not using that buffer at ALL time the file is referenced.
> 
> It's not the file, just the directory information. The data written to a file
> is immediately available via other handles to the same file.
> 

I would still say this is broken.  If I have written data to a file, the
entire Filesystem should know that I have done it.  This happens in
Windows, and it is possible for a user to write data to a file, check on
the file in NT's expoder, and not have the file updated.  This is because
the programmer didn't flush the buffers, or close the file.  The
programmer is assuming the OS will keep everything up to date.  With at
least these two platforms, the OS is NOT keeping the filesystem in synch.

> When is it so important for the directory entry to be up date before the file
> is closed? If the actual size is really needed it can be queried using the

See above

Ryan
_______________________________________________________________________
Ryan Bloom		rbb@raleigh.ibm.com
4205 S Miami Blvd	
RTP, NC 27709		It's a beautiful sight to see good dancers 
			doing simple steps.  It's a painful sight to
			see beginners doing complicated patterns.	



Mime
View raw message