in reply to Re: Don't use unflock (flock 8). Ever.
in thread flock - lordy me....
open F, "+<somefile" or die; while (1) { flock F, 2; seek(F, 1, 0); # this is the part people forget, resyncs the buffer hack(\*F); # work with F in any way you want flock F, 8; # flush and unlock }
-- Randal L. Schwartz, Perl hacker
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: Don't use unflock (flock 8). Ever.
by AgentM (Curate) on Jan 16, 2001 at 23:28 UTC |