Your message dated Mon, 3 Aug 2009 21:06:39 +0200 (CEST)
with message-id <[email protected]>
and subject line Re: Bug#539812: lockfile: Exit code does not always change
with !- option.
has caused the Debian Bug report #539812,
regarding lockfile: Exit code does not always change with !- option.
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)
--
539812: http://bugs.debian.org/cgi-bin/bugreport.cgi?bug=539812
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: procmail
Version: 3.22-16
Severity: grave
Hi,
It seems that the !- doesn't always have an effect on the return
value:
k...@intrepid:~$ rm -f /tmp/lockfile
k...@intrepid:~$ lockfile -! -l 3600 /tmp/lockfile
k...@intrepid:~$ echo $?
73
k...@intrepid:~$ rm -f /tmp/lockfile
k...@intrepid:~$ lockfile -l 3600 /tmp/lockfile
k...@intrepid:~$ echo $?
0
k...@intrepid:~$ lockfile -! -l 3600 /tmp/lockfile
lockfile: Signal received, giving up on "/tmp/lockfile"
k...@intrepid:~$ echo $?
75
k...@intrepid:~$ lockfile -l 3600 /tmp/lockfile
lockfile: Signal received, giving up on "/tmp/lockfile"
k...@intrepid:~$ echo $?
75
I would expect to receive 0 in the 3rd case, it did
not succesfully aquire the lock.
Kurt
--- End Message ---
--- Begin Message ---
On Mon, 3 Aug 2009, Kurt Roeckx wrote:
> On Mon, Aug 03, 2009 at 08:25:00PM +0200, Kurt Roeckx wrote:
> > Package: procmail
> > Version: 3.22-16
> > Severity: grave
> >
> > Hi,
> >
> > It seems that the !- doesn't always have an effect on the return
> > value:
> [...]
>
> So it seems the manpage says this:
> Using lockfile as the condition of a loop in a shell script
> can be done easily by using the -! flag to invert the exit
> status. To prevent infinite loops, failures for any reason
> other than the lockfile already existing are not inverted to
> success but rather are still returned as failures.
Exactly. So, as behaviour matches documentation, this is not a bug.
--- End Message ---