Track PID
This commit is contained in:
parent
2559d13d38
commit
d8ae0c1c48
|
@ -13,6 +13,13 @@ my $lat_lon = fetch_lat_lon($location);
|
||||||
|
|
||||||
my $pid = fork;
|
my $pid = fork;
|
||||||
unless ($pid) {
|
unless ($pid) {
|
||||||
|
open(my $fh, ">", $ENV{HOME}."/.spool/gammastep.pid");
|
||||||
|
print $fh $$;
|
||||||
|
close($fh);
|
||||||
|
open($fh, ">", $ENV{HOME}."/.spool/gammastep.status");
|
||||||
|
print $fh 1;
|
||||||
|
close($fh);
|
||||||
|
|
||||||
open STDIN, '/dev/null';
|
open STDIN, '/dev/null';
|
||||||
open STDOUT, '>>/dev/null';
|
open STDOUT, '>>/dev/null';
|
||||||
open STDERR, '>>/dev/null';
|
open STDERR, '>>/dev/null';
|
||||||
|
|
Loading…
Reference in New Issue