From 98bb98ffedc7c761398f759eb138216fadbf6dbb Mon Sep 17 00:00:00 2001 From: "Alexander \"Arav\" Andreev" Date: Sun, 2 Jan 2022 05:26:24 +0400 Subject: [PATCH] IsProcessUp was ditched in favor of GetProcessPIDs. --- prog/server.go | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/prog/server.go b/prog/server.go index dde888c..134673f 100644 --- a/prog/server.go +++ b/prog/server.go @@ -48,8 +48,8 @@ func AreProcessesUp(processes *[]string) func(http.ResponseWriter, *http.Request proclist := NewProcessList() for _, proc := range *processes { - isup, _, _ := IsProcessUp(proc) - proclist.AddProcess(proc, isup) + pids, err := GetProcessPIDs(proc) + proclist.AddProcess(proc, err == nil && len(pids) > 0) } if hdr := r.Header.Get("Accept"); hdr == "application/xml" {