Subject: | Please implement option to control lock file _contents_ |
Date: | Mon, 2 Jun 2008 13:57:04 +0200 |
To: | bug-LockFile-Simple [...] rt.cpan.org |
From: | Marc Haber <mh+bug-lockfile-simple [...] zugschlus.de> |
Hi,
currentl, LockFile::Simple writes the current PID to the lock file
without leading spaces, and adds the host name if the lock file is on
NFS.
The FHS (2.3) demands that lock files in /var/lock are created in the
HDB UUCP lock file format, which specifies that the PID is to be right
justified as a ten bytes ASCII decimal number.
For example, if process 1230 holds a lock file, it would contain the
eleven characters: space, space, space, space, space, space, one, two,
three, zero, and newline.
It would be great if LockFile::Simple could create lock files
conforming to this standard.
This could, for example, be implemented by printing the pid to the
lock file via printf and allowing the user to specify the format
string (of course, after appropriate sanitazion).
Please consider implementing this in a future version of
LockFile::Simple.
Greetings
Marc
--
-----------------------------------------------------------------------------
Marc Haber | "I don't trust Computers. They | Mailadresse im Header
Mannheim, Germany | lose things." Winona Ryder | Fon: *49 621 72739834
Nordisch by Nature | How to make an American Quilt | Fax: *49 3221 2323190