Cool. I've often used flock to ensure only one instance of a program is running, but I never thought of opening $0 and locking that - consequently each of my scripts litters the filesystem with a matching .lck file.
In reply to Re: File Locking Tricks and Traps
by grantm
in thread File Locking Tricks and Traps
by Dominus
| For: | Use: | ||
| & | & | ||
| < | < | ||
| > | > | ||
| [ | [ | ||
| ] | ] |