#296 Fix occasional empty macsuck when run in daemon
This commit is contained in:
@@ -4,6 +4,10 @@
|
||||
|
||||
* #27 add SNMP tips for Huawei, CloudEngine, Linksys (stoatwblr)
|
||||
|
||||
[BUG FIXES]
|
||||
|
||||
* #296 Fix occasional empty macsuck when run in daemon
|
||||
|
||||
2.034002 - 2017-01-06
|
||||
|
||||
[ENHANCEMENTS]
|
||||
|
||||
@@ -40,15 +40,7 @@ sub worker_body {
|
||||
};
|
||||
|
||||
$self->close_job($job);
|
||||
|
||||
# restart worker once a day.
|
||||
my $hour = [localtime()]->[2];
|
||||
if ($wid) {
|
||||
if ((time >= ($self->{started} + 86400) and $hour == ($wid % 24))
|
||||
or (time > ($self->{started} + 172800))) {
|
||||
$self->exit(0, "recycling worker $wid");
|
||||
}
|
||||
}
|
||||
$self->exit(0); # recycle worker
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user