diff --git a/os/gctx/gctx.go b/os/gctx/gctx.go index 02a8d6083..686ed8aad 100644 --- a/os/gctx/gctx.go +++ b/os/gctx/gctx.go @@ -33,6 +33,9 @@ func init() { i := 0 for _, s := range os.Environ() { i = strings.IndexByte(s, '=') + if i == -1 { + continue + } m[s[0:i]] = s[i+1:] } // OpenTelemetry from environments.