envknob: remove some stutter from error messages

The strconv errors already stringified with the same.

Change-Id: I6938c5653e9aafa6d9028d45fc26e39eb9ccbaea
Signed-off-by: Brad Fitzpatrick <bradfitz@tailscale.com>
This commit is contained in:
Brad Fitzpatrick 2022-02-12 16:21:41 -08:00 committed by Brad Fitzpatrick
parent 3a94ece30c
commit be9d564c29

View File

@ -53,7 +53,7 @@ func boolOr(envVar string, implicitValue bool) bool {
if err == nil {
return b
}
log.Fatalf("invalid environment variable %s value %q: %v", envVar, val, err)
log.Fatalf("invalid boolean environment variable %s value %q", envVar, val)
panic("unreachable")
}
@ -69,7 +69,7 @@ func LookupBool(envVar string) (v bool, ok bool) {
if err == nil {
return b, true
}
log.Fatalf("invalid environment variable %s value %q: %v", envVar, val, err)
log.Fatalf("invalid boolean environment variable %s value %q", envVar, val)
panic("unreachable")
}
@ -97,7 +97,7 @@ func LookupInt(envVar string) (v int, ok bool) {
if err == nil {
return v, true
}
log.Fatalf("invalid environment variable %s value %q: %v", envVar, val, err)
log.Fatalf("invalid integer environment variable %s: %v", envVar, val)
panic("unreachable")
}