Closed cmars closed 8 years ago
There's a race condition in which PipeListener.Accept and PipeListener.Close are called from separate goroutines. Either method can mutate the state of the PipeListener (l.closed, l.handler). These sections need to be protected with a mutex.
Trying to fix the test hang issue in https://bugs.launchpad.net/juju-core/+bug/1581157. The thing is, I think the same thing could happen to the uniter.
See #19 for my latest attempt at fixing this...
There's a race condition in which PipeListener.Accept and PipeListener.Close are called from separate goroutines. Either method can mutate the state of the PipeListener (l.closed, l.handler). These sections need to be protected with a mutex.