MCPcopy
hub / github.com/uber-go/goleak / isStdLibStack

Function isStdLibStack

options.go:189–198  ·  view source on GitHub ↗
(s stack.Stack)

Source from the content-addressed store, hash-verified

187}
188
189func isStdLibStack(s stack.Stack) bool {
190 // Importing os/signal starts a background goroutine.
191 // The name of the function at the top has changed between versions.
192 if f := s.FirstFunction(); f == "os/signal.signal_recv" || f == "os/signal.loop" {
193 return true
194 }
195
196 // Using signal.Notify will start a runtime goroutine.
197 return s.HasFunction("runtime.ensureSigM")
198}

Callers

nothing calls this directly

Calls 2

FirstFunctionMethod · 0.80
HasFunctionMethod · 0.80

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…