Justin Vallon <vallon(a)mindspring.com> writes in xemacs-beta(a)xemacs.org:
On Fri, 6 Nov 1998, Kyle Jones wrote:
> > > Fix #2: Change order of close and stat
> >
> > This would seem to be the correct solution. On other systems it should
> > not make any difference. The only thing is, why wasn't it done before?
>
> stat() is relatively expensive compared to fstat(). Also, it
> is surprising (to me) that close() would fiddle with the file
> modtime, given that close() does no implicit flushing of data.
I seem to remember somewhere that NFS writes may be postponed until
close().
This brings back bad memories of old flame wars. I don't think NFS
will do this, but I know AFS can raise errors on close. If Dejanews
has restored enough old netnews, there should be megabytes on this
topic in the old archives.
That is, close() may give errors such as disk full, etc, because
for performance reasons, write() is only done locally and disk allocation
is not done until close [or a later write].
Something like that, as I recall.