From 0dbcd7241e02071175b14b614af7f2fdff08215d Mon Sep 17 00:00:00 2001 From: Jozef Reisinger Date: Tue, 16 May 2023 12:39:14 +0200 Subject: [PATCH] better error message --- check/tls.go | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/check/tls.go b/check/tls.go index 9e76a97..39e3e37 100644 --- a/check/tls.go +++ b/check/tls.go @@ -4,6 +4,7 @@ import ( "crypto/tls" "encoding/json" "errors" + "fmt" "net" "strings" "syscall" @@ -61,7 +62,7 @@ func Tls(ipaddr net.IP) (checkip.Result, error) { } } - return result, newCheckError(err) + return result, newCheckError(fmt.Errorf("connect to %s: %v", address, err)) } defer conn.Close()