Fixed a heartbeat ignore bug.
This commit is contained in:
+2
-1
@@ -90,7 +90,8 @@ class MethodExecutor
|
|||||||
while true
|
while true
|
||||||
sleep 0.5
|
sleep 0.5
|
||||||
begin
|
begin
|
||||||
proc_status = Process.waitpid2(pid, Process::WNOHANG)
|
SystemdNotifier.notify("WATCHDOG=1")
|
||||||
|
proc_status = Process.waitpid2(pid, Process::WNOHANG)
|
||||||
if proc_status # 子进程已退出,返回 [pid, status]
|
if proc_status # 子进程已退出,返回 [pid, status]
|
||||||
_, status = proc_status
|
_, status = proc_status
|
||||||
elapsed = (Time.now - tick_beg).round(2)
|
elapsed = (Time.now - tick_beg).round(2)
|
||||||
|
|||||||
Reference in New Issue
Block a user