more pidfile fixing
parent
c375152b9e
commit
29c3635e49
3
kuvert
3
kuvert
|
@ -20,7 +20,7 @@
|
|||
# along with this program; if not, write to the Free Software
|
||||
# Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
|
||||
#
|
||||
# $Id: kuvert,v 2.5 2003/02/05 22:45:39 az Exp az $
|
||||
# $Id: kuvert,v 2.6 2003/02/08 13:08:06 az Exp az $
|
||||
#--
|
||||
|
||||
use strict;
|
||||
|
@ -104,6 +104,7 @@ sub main
|
|||
open(PIDF,">$pidf") || &bailout("cant open >$pidf: $!");
|
||||
}
|
||||
my $other=<PIDF>;
|
||||
chomp $other;
|
||||
seek(PIDF,0,'SEEK_SET');
|
||||
logit("there seems to be another instance with PID $other") if ($other);
|
||||
&bailout("cant lock $pidf ($!), exiting.")
|
||||
|
|
Loading…
Reference in New Issue