Normally all filehandles (except STDERR, I think) are buffered.
That means that if you write a character (or a byte) on a filehandle,
the system does not write it on the disk immediatly, but waits till it's
buffer is full and than writes the whole buffer. This saves many
IO-Operations,
which results in better performance.
With flushing a filehandle you tell the system to empty the buffer for
this
filehandle and writes everything in it to the disk.
hope this helps,
cr
On Thu, 17 May 2001 16:59:08 +0300 (EEST), kosta said:
> hi!
>
> Question: What is "flush"? and how can a filehandle be flushed? I saw such a phrase
>while looking for info about file locking.
>
> thanks in advance,
> kosta
>