Whenever a child context is created via WithRootCancel, a goroutine
spawns to gracefully handle closing the child context whenever the root
context gets canceled.
However, the current implementation leaks goroutines whenever the child
context exits before the root context exits.
Whenever a child context is created via
WithRootCancel
, a goroutine spawns to gracefully handle closing the child context whenever the root context gets canceled.However, the current implementation leaks goroutines whenever the child context exits before the root context exits.