From 43046488d5bfb0e09d36c71cf2373abaa8e5d80c Mon Sep 17 00:00:00 2001 From: Alexander Thaller Date: Wed, 5 Dec 2018 14:47:27 +0100 Subject: [PATCH] Fixed ping plugin under bsd variants. They dont have a flag called -w but a flag -W which was probably desired here. --- plugins/inputs/ping/ping.go | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/plugins/inputs/ping/ping.go b/plugins/inputs/ping/ping.go index 53c109d754db5..1d49cccc4551d 100644 --- a/plugins/inputs/ping/ping.go +++ b/plugins/inputs/ping/ping.go @@ -206,7 +206,7 @@ func (p *Ping) args(url string, system string) []string { case "darwin": args = append(args, "-W", strconv.FormatFloat(p.Timeout*1000, 'f', -1, 64)) case "freebsd", "netbsd", "openbsd": - args = append(args, "-w", strconv.FormatFloat(p.Timeout*1000, 'f', -1, 64)) + args = append(args, "-W", strconv.FormatFloat(p.Timeout*1000, 'f', -1, 64)) case "linux": args = append(args, "-W", strconv.FormatFloat(p.Timeout, 'f', -1, 64)) default: