As it says in the docs flock :-
locks are merely advisory
Exactly what happens will depend on the operating system you're on, what other process is trying to write to the file, and the exact timing of the writes.
IMHO flock just isn't worth using, it's almost entirely pointless.
In reply to Re: Question about flock and printing to file
by RichardK
in thread Question about flock and printing to file
by deruytja
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |